mirror of
https://github.com/vitest-dev/vitest.git
synced 2025-12-08 18:26:03 +00:00
20 lines
410 B
TypeScript
20 lines
410 B
TypeScript
import { expect, test } from 'vitest'
|
|
import { runBrowserTests } from './utils'
|
|
|
|
test('viewport', async () => {
|
|
const { stderr, ctx } = await runBrowserTests({
|
|
root: './fixtures/viewport',
|
|
})
|
|
|
|
expect(stderr).toBe('')
|
|
expect(
|
|
Object.fromEntries(
|
|
ctx.state.getFiles().map(f => [f.name, f.result.state]),
|
|
),
|
|
).toMatchInlineSnapshot(`
|
|
{
|
|
"basic.test.ts": "pass",
|
|
}
|
|
`)
|
|
})
|