test real media sets

This commit is contained in:
Yisroel Baum 2026-05-25 20:05:13 +03:00
parent d385a37266
commit 6e73d64c20
Signed by: yisroelbaum
GPG key ID: 0FA60884F75520A9

View file

@ -1,21 +1,9 @@
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')
it('fetches and renders seeded set cards', () => {
cy.visit('/media')
cy.wait('@fetchSets')
cy.get('[data-cy="media-set-card"]').should('have.length', 1)
cy.get('[data-cy="media-set-card"]', { timeout: 10000 })
.should('have.length', 1)
cy.contains('[data-cy="media-set-card"]', 'Baderech HaAvodah')
.should('be.visible')
})