-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathplaywright.config.ts
More file actions
25 lines (23 loc) · 1.02 KB
/
Copy pathplaywright.config.ts
File metadata and controls
25 lines (23 loc) · 1.02 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
import { defineConfig } from "@playwright/test";
import { existsSync } from "node:fs";
const defaultMacChromePath = "/Applications/Google Chrome.app/Contents/MacOS/Google Chrome";
const chromiumExecutablePath = process.env.A3D_WEBGPU_BROWSER_EXECUTABLE ||
(process.env.A3D_DISABLE_SYSTEM_WEBGPU_BROWSER === "true" ? undefined : existsSync(defaultMacChromePath) ? defaultMacChromePath : undefined);
const chromiumLaunchOptions = {
...(chromiumExecutablePath ? { executablePath: chromiumExecutablePath } : {}),
args: ["--enable-unsafe-webgpu", "--ignore-gpu-blocklist"],
};
export default defineConfig({
testDir: ".",
testMatch: ["tests/browser/**/*.spec.ts", "tests/visual/**/*.spec.ts"],
testIgnore: ["release-artifacts/**"],
timeout: 60_000,
workers: 1,
use: {
browserName: "chromium",
headless: true,
viewport: { width: 800, height: 600 },
launchOptions: chromiumLaunchOptions,
},
reporter: [["list"], ["json", { outputFile: process.env.PLAYWRIGHT_JSON_OUTPUT_NAME ?? "tests/reports/browser.json" }]]
});