chore: 配置与基础设施更新
- 开发服务器端口从 3002 改为 5174 - vitest 配置从 vue plugin 改为 react plugin - playwright 新增 uat 项目配置,修正 baseURL - 添加 less 依赖支持 - 修复各页面 catch 块空语句为注释标记
This commit is contained in:
@@ -6,7 +6,7 @@ const __filename = fileURLToPath(import.meta.url);
|
||||
const __dirname = path.dirname(__filename);
|
||||
|
||||
const isHeadless = process.env.PLAYWRIGHT_HEADLESS === 'true' || process.env.CI === 'true';
|
||||
const baseURL = process.env.TEST_BASE_URL || process.env.VITE_BASE_URL || 'http://localhost:3002';
|
||||
const baseURL = process.env.TEST_BASE_URL || process.env.VITE_BASE_URL || 'http://localhost:5174';
|
||||
|
||||
export default defineConfig({
|
||||
testDir: './e2e',
|
||||
@@ -106,11 +106,26 @@ export default defineConfig({
|
||||
}
|
||||
},
|
||||
},
|
||||
{
|
||||
name: 'uat',
|
||||
testDir: './e2e/uat',
|
||||
testMatch: /.*\.spec\.ts/,
|
||||
use: {
|
||||
...devices['Desktop Chrome'],
|
||||
launchOptions: {
|
||||
args: [
|
||||
'--disable-blink-features=AutomationControlled',
|
||||
'--disable-dev-shm-usage',
|
||||
'--no-sandbox'
|
||||
]
|
||||
}
|
||||
},
|
||||
},
|
||||
],
|
||||
|
||||
webServer: {
|
||||
command: 'npm run dev',
|
||||
url: 'http://localhost:3002',
|
||||
url: 'http://localhost:5174',
|
||||
reuseExistingServer: !process.env.CI,
|
||||
timeout: 180000,
|
||||
stdout: 'pipe',
|
||||
|
||||
Reference in New Issue
Block a user