forked from module-federation/vite
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathplaywright.config.ts
More file actions
38 lines (37 loc) · 945 Bytes
/
Copy pathplaywright.config.ts
File metadata and controls
38 lines (37 loc) · 945 Bytes
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";
export default defineConfig({
testDir: "tests",
timeout: 30 * 1000,
retries: process.env.CI ? 2 : 0,
workers: process.env.CI ? 1 : undefined,
forbidOnly: Boolean(process.env.CI),
webServer: [
{
command: "pnpm run multi-example",
url: "http://localhost:5173",
reuseExistingServer: !process.env.CI,
timeout: 120_000,
},
],
use: {
trace: "retain-on-failure",
screenshot: "only-on-failure",
video: "retain-on-failure",
},
projects: [
{
name: "multi-example",
testDir: "e2e/vite-webpack-rspack",
use: {
baseURL: "http://localhost:5173",
browserName: "chromium",
},
},
],
outputDir: "reports/e2e/output",
reporter: [
["list"],
["html", { outputFolder: "reports/e2e/playwright-report", open: "never" }],
["json", { outputFile: "reports/e2e/test-results.json" }],
],
});