fix tests. msw has issues on firefox with vitest isolation.

This commit is contained in:
Henry Jameson 2026-06-18 19:58:50 +03:00
commit 9d24782cd8
11 changed files with 592 additions and 863 deletions

View file

@ -3,6 +3,7 @@ import { fileURLToPath } from 'node:url'
import { DevTools } from '@vitejs/devtools'
import vue from '@vitejs/plugin-vue'
import vueJsx from '@vitejs/plugin-vue-jsx'
import { playwright } from '@vitest/browser-playwright'
import { defineConfig } from 'vite'
import eslint from 'vite-plugin-eslint2'
import stylelint from 'vite-plugin-stylelint'
@ -240,8 +241,10 @@ export default defineConfig(async ({ mode, command }) => {
exclude: [...configDefaults.exclude, 'test/e2e-playwright/**'],
browser: {
enabled: true,
provider: 'playwright',
instances: [{ browser: 'firefox' }],
headless: true,
provider: playwright(),
// https://github.com/mswjs/msw/issues/2757
instances: [{ browser: 'chromium' }],
},
},
}