Skip to content

Commit fb0dea2

Browse files
committed
test: satisfy typescript
1 parent e7b0784 commit fb0dea2

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

examples/app-vitest-full/tests/nuxt/routing.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import App from '~/app.vue'
66

77
describe('routing', () => {
88
it('defaults to index page', async () => {
9-
expect(useRoute().matched[0].meta).toMatchInlineSnapshot(`
9+
expect(useRoute().matched[0]!.meta).toMatchInlineSnapshot(`
1010
{
1111
"value": "set in index",
1212
}

examples/app-vitest-full/tests/nuxt/server.spec.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@ describe('server mocks and data fetching', () => {
1414
eventHandler(() => ({ id: 1 })),
1515
)
1616
const server = await listen(toNodeListener(app))
17-
const [{ url }] = await server.getURLs()
17+
const urls = await server.getURLs()
18+
const { url } = urls[0]!
1819
expect(await $fetch<unknown>('/todos/1', { baseURL: url })).toMatchObject({
1920
id: 1,
2021
})

0 commit comments

Comments
 (0)