You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
vitepress/__tests__/e2e/dynamic-routes/dynamic-routes.test.ts

12 lines
423 B

describe('dynamic routes', () => {
test('render correct content', async () => {
await goto('/dynamic-routes/foo')
expect(await page.textContent('h1')).toMatch('Foo')
expect(await page.textContent('pre.params')).toMatch('"id": "foo"')
await goto('/dynamic-routes/bar')
expect(await page.textContent('h1')).toMatch('Bar')
expect(await page.textContent('pre.params')).toMatch('"id": "bar"')
})
})