-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathplaywright.config.ts
49 lines (46 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
48
49
import { PlaywrightTestConfig, devices } from "@playwright/test";
const config: PlaywrightTestConfig = {
testDir: "./e2e",
testMatch: "e2e/*.spec.ts",
testIgnore: "**/util/**",
timeout: 30 * 1000,
expect: {
timeout: 5000,
},
fullyParallel: true,
reporter: [["html", { open: "never" }]],
use: {
baseURL: "http://localhost:3000",
trace: "on-first-retry",
screenshot: "only-on-failure", // Options: 'on', 'off', 'only-on-failure'
},
projects: [
{
name: "chromium",
use: {
...devices["Desktop Chrome"],
},
},
],
webServer: [
{
// killport is a hack to get around playwright's bizarre globalSetup
command: "killport 3011 && go run ./cmd/scr",
port: 3011,
env: { PORT: "3011" },
reuseExistingServer: true,
timeout: 60000,
},
{
command: "bun run dev",
port: 3010,
env: {
PORT: "3010",
API_URL: "http://localhost:3011",
},
reuseExistingServer: true,
timeout: 60000,
},
],
};
export default config;