-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathplaywright.config.ts
More file actions
33 lines (29 loc) · 1.01 KB
/
Copy pathplaywright.config.ts
File metadata and controls
33 lines (29 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
import { defineConfig, devices } from "@playwright/test";
export default defineConfig({
testDir: "./e2e",
fullyParallel: false, // clipboard tests must run serially to avoid interference
retries: process.env.CI ? 2 : 0,
workers: 1, // one worker — clipboard is a shared system resource
reporter: [["list"], ["html", { open: "never" }]],
use: {
baseURL: "http://localhost:5173",
trace: "on-first-retry",
// Grant clipboard permissions so tests can read what was written
permissions: ["clipboard-read", "clipboard-write"],
// Chromium is required — Firefox and WebKit handle clipboard differently
// and Web Workers behave differently in each. We test the primary target.
},
projects: [
{
name: "chromium",
use: { ...devices["Desktop Chrome"] },
},
],
// Start the Vite dev server automatically before running tests
webServer: {
command: "npm run dev",
url: "http://localhost:5173",
reuseExistingServer: !process.env.CI,
timeout: 30_000,
},
});