Skip to content

Commit

Permalink
test: throw error for @vitest/browser/context
Browse files Browse the repository at this point in the history
  • Loading branch information
sheremet-va committed Oct 2, 2024
1 parent f95612c commit 3e7b116
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
3 changes: 3 additions & 0 deletions test/cli/fixtures/fails/node-browser-context.test.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import { page } from '@vitest/browser/context'

console.log(page)
2 changes: 2 additions & 0 deletions test/cli/test/__snapshots__/fails.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ exports[`should fail nested-suite.test.ts > nested-suite.test.ts 1`] = `"Asserti
exports[`should fail no-assertions.test.ts > no-assertions.test.ts 1`] = `"Error: expected any number of assertion, but got none"`;
exports[`should fail node-browser-context.test.ts > node-browser-context.test.ts 1`] = `"Error: @vitest/browser/context can be imported only inside the Browser Mode. Your test is running in forks pool. Make sure your regular tests are excluded from the "test.include" glob pattern."`;
exports[`should fail primitive-error.test.ts > primitive-error.test.ts 1`] = `"Unknown Error: 42"`;
exports[`should fail snapshot-with-not.test.ts > snapshot-with-not.test.ts 1`] = `
Expand Down

0 comments on commit 3e7b116

Please sign in to comment.