Repository navigation
Expand file tree
/
Copy pathplaywright.config.js
More file actions
51 lines (51 loc) · 1.58 KB
/
Copy pathplaywright.config.js
File metadata and controls
51 lines (51 loc) · 1.58 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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
import { defineConfig, devices } from "@playwright/test";
// Parallel checkouts each set their own E2E_PORT so their servers never mix.
const port = Number(process.env.E2E_PORT) || 5198;
export default defineConfig({
testDir: "./e2e",
fullyParallel: true,
timeout: 30000,
use: {
baseURL: `http://127.0.0.1:${port}`,
trace: "retain-on-failure",
// Specs written against a blank first slide keep it: new presentations
// start with the blank slide the app offers as a preference. Specs about
// the Title Slide start (e2e/layouts.spec.js) clear this. The AI
// assistant opens with a deck unless closed; specs keep the full-width
// slide they were written against (e2e/assistant.spec.js tests the default).
storageState: {
cookies: [],
origins: [
{
origin: `http://127.0.0.1:${port}`,
localStorage: [
{ name: "presentation:start", value: "blank" },
{ name: "presentation:assistant", value: '{"open":false}' },
],
},
],
},
},
webServer: {
command: `npm run dev -- --host 127.0.0.1 --port ${port} --strictPort`,
url: `http://127.0.0.1:${port}`,
reuseExistingServer: !process.env.CI,
},
projects: [
{
name: "desktop",
use: {
...devices["Desktop Chrome"],
viewport: { width: 1440, height: 960 },
},
},
{
name: "mobile",
use: { ...devices["iPhone 13"], defaultBrowserType: "chromium" },
},
{
name: "tablet",
use: { ...devices["iPad Mini"], defaultBrowserType: "chromium" },
},
],
});