-
Notifications
You must be signed in to change notification settings - Fork 1.3k
/
playwright.config.ts
47 lines (44 loc) · 1.05 KB
/
playwright.config.ts
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
41
42
43
44
45
46
47
import type { PlaywrightTestConfig } from '@playwright/test';
import { devices } from '@playwright/test';
const isCI = !!process.env.CI;
const config: PlaywrightTestConfig = {
testDir: 'apps/calendar/playwright',
testMatch: '*.e2e.ts',
fullyParallel: !isCI,
timeout: 30000,
forbidOnly: isCI,
// eslint-disable-next-line no-undefined
workers: isCI ? 2 : undefined,
use: {
trace: isCI ? 'off' : 'retain-on-failure',
viewport: {
width: 1600,
height: 900,
},
launchOptions: {
slowMo: 250,
},
timezoneId: 'Asia/Seoul',
},
webServer: {
command: isCI ? 'npm run serve:storybook' : 'npm run storybook --workspace=@toast-ui/calendar',
port: isCI ? 8080 : 6006,
timeout: 120 * 1000,
reuseExistingServer: !isCI,
},
projects: [
{
name: 'Chromium',
use: { ...devices['Desktop Chrome'] },
},
{
name: 'Safari',
use: { ...devices['Desktop Safari'] },
},
{
name: 'Firefox',
use: { ...devices['Desktop Firefox'] },
},
],
};
export default config;