-
Notifications
You must be signed in to change notification settings - Fork 217
Expand file tree
/
Copy pathplaywright.prod.config.ts
More file actions
40 lines (38 loc) · 1.22 KB
/
Copy pathplaywright.prod.config.ts
File metadata and controls
40 lines (38 loc) · 1.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
import { defineConfig, devices } from '@playwright/test';
/**
* Production smoke: the core suites against the deployed site, not a local
* build (matrix section C "线上站"). Serial and patient: the first x2t.wasm
* fetch (~10 MB) dominates and parallel workers would starve each other.
* PROD_URL=https://edit.chaxus.com pnpm exec playwright test -c playwright.prod.config.ts
*/
const PROD_URL = process.env.PROD_URL || 'https://edit.chaxus.com';
export default defineConfig({
testDir: 'test/e2e',
testMatch: [
'app-smoke.spec.ts',
'embed-regression.spec.ts',
'embed-save-default.spec.ts',
'main-site.spec.ts',
'open-failure.spec.ts',
'html-as-xls.spec.ts',
'sw-warm.spec.ts',
'format-parity.spec.ts',
'font-cache.spec.ts',
'pdf-route.spec.ts',
'pdf-roundtrip.spec.ts',
],
timeout: 300_000,
expect: { timeout: 10_000 },
fullyParallel: false,
workers: 1,
retries: 1,
outputDir: 'test-results-prod',
reporter: [['list'], ['html', { outputFolder: 'playwright-report-prod', open: 'never' }]],
use: {
baseURL: PROD_URL,
trace: 'retain-on-failure',
screenshot: 'only-on-failure',
...devices['Desktop Chrome'],
viewport: { width: 1280, height: 900 },
},
});