-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.config.ts
40 lines (35 loc) · 1.02 KB
/
index.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
import { devices, PlaywrightTestConfig } from "@playwright/test";
const indexConfig: PlaywrightTestConfig = {
forbidOnly: !!process.env.CI,
// timeout: process.env.CI ? 5 * 6 * 1000 : 0,
globalTimeout: process.env.CI ? 15 * 100 * 1000 : undefined,
retries: process.env.CI ? 0 : 0,
// Opt out of parallel tests on CI.
workers: process.env.CI ? 1 : 1,
reporter: process.env.CI ? [["html"]] : [["html"]],
use: {
// Emulate browsing in San Francisco, CA, USA
locale: "en-GB",
timezoneId: "IST",
geolocation: { latitude: 13.081585811267423, longitude: 80.27697382248456 },
// Report failure(s)
screenshot: "only-on-failure",
video: process.env.CI ? "retain-on-failure" : "retain-on-failure",
trace: {
mode: "retain-on-failure",
},
},
projects: [
{
name: "chromium",
use: {
...devices["Desktop Chromium"],
viewport: null,
launchOptions: {
args: ["--start-maximized"],
},
},
},
],
};
export default indexConfig;