File tree Expand file tree Collapse file tree 3 files changed +86
-184
lines changed
Expand file tree Collapse file tree 3 files changed +86
-184
lines changed Original file line number Diff line number Diff line change 6161 "typescript" : " ^5.9.3" ,
6262 "typescript-eslint" : " ^8.46.3" ,
6363 "vite" : " catalog:" ,
64- "vitest" : " ^3.2.4 " ,
64+ "vitest" : " ^4.0.8 " ,
6565 "vue" : " catalog:"
6666 },
6767 "simple-git-hooks" : {
Original file line number Diff line number Diff line change @@ -20,7 +20,6 @@ import {
2020 preview ,
2121} from 'vite'
2222import type { Browser , Page } from 'playwright-chromium'
23- import type { File } from 'vitest'
2423import { beforeAll } from 'vitest'
2524
2625// #region env
@@ -92,13 +91,7 @@ export function setViteUrl(url: string): void {
9291
9392const DIR = join ( os . tmpdir ( ) , 'vitest_playwright_global_setup' )
9493
95- beforeAll ( async ( s ) => {
96- const suite = s as File
97- // skip browser setup for non-playground tests
98- if ( ! suite . filepath . includes ( 'playground' ) ) {
99- return
100- }
101-
94+ beforeAll ( async ( suite ) => {
10295 const wsEndpoint = fs . readFileSync ( join ( DIR , 'wsEndpoint' ) , 'utf-8' )
10396 if ( ! wsEndpoint ) {
10497 throw new Error ( 'wsEndpoint not found' )
@@ -132,7 +125,7 @@ beforeAll(async (s) => {
132125 browserErrors . push ( error )
133126 } )
134127
135- testPath = suite . filepath !
128+ testPath = suite . file . filepath
136129 testName = slash ( testPath ) . match ( / p l a y g r o u n d \/ ( [ \w - ] + ) \/ / ) ?. [ 1 ]
137130 testDir = dirname ( testPath )
138131
You can’t perform that action at this time.
0 commit comments