test introduction pdf

This commit is contained in:
Yisroel Baum 2026-05-27 21:50:23 +03:00
parent 6cb215a7bf
commit c1f6437769
Signed by: yisroelbaum
GPG key ID: 0FA60884F75520A9
2 changed files with 8 additions and 1 deletions

View file

@ -75,6 +75,10 @@ class DemoSeedDataTest extends TestCase
$this->expectedIntroductionRichText(),
$childElements[0]->getRichText(),
);
$this->assertSame(
'/assets/pdfs/baderech.pdf',
$childElements[0]->getPdfPath(),
);
}
private function serializeChildElements(array $childElements): array

View file

@ -108,6 +108,9 @@ describe('media page sets', () => {
.and('contain.text', 'So many are Hashkafikly homeless')
.and('contain.text', 'the life we were created for.')
cy.get('[data-cy="element-youtube-embed"]').should('not.exist')
cy.get('[data-cy="element-pdf-link"]').should('not.exist')
cy.contains('[data-cy="element-pdf-link"]', 'View PDF')
.should('be.visible')
.and('have.attr', 'href', '/assets/pdfs/baderech.pdf')
.and('have.attr', 'target', '_blank')
})
})