fix: synchronize CHRNX fixture permalinks

This commit is contained in:
chrnx committed 2026-08-12 14:14:47 -05:00
1 parent f4e122f52e
commit 05dfe83a49
4 files changed
+79 -3

No files matched your search

+20
View File
@@ -35,6 +35,26 @@ test( 'home remains coherent at all approved review viewports', async ( { page }
}
} );
test( 'seeded post permalink resolves its single template', async ( { page } ) => {
const title = 'The save file remembers what the hero pretends to forget';
const expectedPath = '/the-save-file-remembers-what-the-hero-pretends-to-forget/';
await page.goto( '/' );
const fixtureCard = page.locator( '.chrnx-featured-story', { hasText: title } );
await expect( fixtureCard.getByRole( 'heading', { name: title, exact: true } ) ).toBeVisible();
const fixtureLink = fixtureCard.getByRole( 'link' );
const [ navigationResponse ] = await Promise.all( [
page.waitForNavigation(),
fixtureLink.click(),
] );
expect( navigationResponse ).not.toBeNull();
expect( navigationResponse.status() ).toBe( 200 );
await expect( page ).toHaveURL( new RegExp( `${ expectedPath }$` ) );
await expect( page.locator( 'main.chrnx-entry--single' ) ).toBeVisible();
await expect( page.getByRole( 'heading', { level: 1, name: title, exact: true } ) ).toBeVisible();
} );
test( 'topic, music, podcast, and about surfaces use real content and approved art', async ( {
page,
} ) => {