test media set cards
This commit is contained in:
parent
c4b95137e5
commit
d385a37266
1 changed files with 22 additions and 0 deletions
22
frontend/rabbi_gerzi/cypress/e2e/media.cy.ts
Normal file
22
frontend/rabbi_gerzi/cypress/e2e/media.cy.ts
Normal file
|
|
@ -0,0 +1,22 @@
|
||||||
|
describe('media page sets', () => {
|
||||||
|
it('fetches and renders set cards', () => {
|
||||||
|
cy.intercept('GET', '**/api/sets', {
|
||||||
|
statusCode: 200,
|
||||||
|
body: {
|
||||||
|
sets: [
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
name: 'Baderech HaAvodah',
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
}).as('fetchSets')
|
||||||
|
|
||||||
|
cy.visit('/media')
|
||||||
|
|
||||||
|
cy.wait('@fetchSets')
|
||||||
|
cy.get('[data-cy="media-set-card"]').should('have.length', 1)
|
||||||
|
cy.contains('[data-cy="media-set-card"]', 'Baderech HaAvodah')
|
||||||
|
.should('be.visible')
|
||||||
|
})
|
||||||
|
})
|
||||||
Loading…
Add table
Add a link
Reference in a new issue