-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathplaywright.examples.config.ts
More file actions
38 lines (36 loc) · 1.01 KB
/
Copy pathplaywright.examples.config.ts
File metadata and controls
38 lines (36 loc) · 1.01 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
import { defineConfig } from '@playwright/test'
const examplesReportFolder = 'playwright-report-examples'
export default defineConfig({
testDir: './test',
testMatch: 'examples.test.ts',
fullyParallel: true,
retries: process.env.CI ? 1 : 0,
workers: process.env.CI ? 2 : undefined,
timeout: 30_000,
expect: {
timeout: 5_000,
},
// A separate folder from the main suite's report: both suites run in the
// same CI job, and the default folder would leave only the last one.
reporter: process.env.CI
? [['dot'], ['html', { open: 'never', outputFolder: examplesReportFolder }]]
: [
['list'],
['html', { open: 'never', outputFolder: examplesReportFolder }],
],
use: {
baseURL: 'http://localhost:4567',
trace: 'retain-on-failure',
},
projects: [
{
name: 'chromium',
use: { browserName: 'chromium' },
},
],
webServer: {
command: 'npx serve examples -l 4567 --no-clipboard',
port: 4567,
reuseExistingServer: !process.env.CI,
},
})