forked from nimbalyst/nimbalyst
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathplaywright.config.ts
More file actions
36 lines (32 loc) · 912 Bytes
/
Copy pathplaywright.config.ts
File metadata and controls
36 lines (32 loc) · 912 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
import { defineConfig } from '@playwright/test';
import path from 'node:path';
import { fileURLToPath } from 'node:url';
const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
const electronE2EDir = path.join(__dirname, 'packages/electron/e2e');
if (!process.env.TS_NODE_PROJECT) {
process.env.TS_NODE_PROJECT = path.join(__dirname, 'tsconfig.playwright.json');
}
export default defineConfig({
testDir: electronE2EDir,
fullyParallel: false,
timeout: 120_000,
expect: {
timeout: 10_000,
},
retries: process.env.CI ? 1 : 0,
reporter: process.env.CI
? [['list'], ['junit', { outputFile: 'playwright-report/electron-e2e.xml' }]]
: [['list']],
use: {
trace: 'on-first-retry',
screenshot: 'only-on-failure',
video: 'retain-on-failure',
},
projects: [
{
name: 'electron',
testDir: electronE2EDir,
},
],
});