-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathplaywright.local-network.config.ts
More file actions
59 lines (53 loc) · 1.76 KB
/
Copy pathplaywright.local-network.config.ts
File metadata and controls
59 lines (53 loc) · 1.76 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
52
53
54
55
56
57
58
59
/**
* Playwright config for local-network e2e tests.
*
* These tests require a full local Aztec network (sequencer + node + PXE).
* Playwright manages both the app server and the Aztec node as webServer
* processes, so the suite is fully self-contained:
*
* yarn test:e2e:local-network # dev machine (reuses existing servers)
* CI=true yarn test:e2e:local-network # CI (starts everything from scratch)
*
* Contracts are automatically deployed via the wallet fixture before tests run.
*/
import { defineConfig, devices } from '@playwright/test';
export default defineConfig({
testDir: './tests/e2e/local-network',
fullyParallel: false,
workers: 1,
forbidOnly: !!process.env.CI,
reporter: 'list',
use: {
baseURL: 'http://localhost:3000',
// Default to headless for stability; opt-in to headed mode with PW_HEADED=true.
headless: process.env.PW_HEADED !== 'true',
launchOptions: { devtools: process.env.PW_DEVTOOLS === 'true' },
},
expect: { timeout: 30_000 },
// Allow 10 minutes per test — the first run for each test needs to:
// 1. Load the WASM PXE bundle and sync (30-60s on a loaded machine)
// 2. Execute private circuits (MLP can take 30-90s on first simulate)
// 3. Submit and wait for a tx to reach PROPOSED status (30-60s)
timeout: 600_000,
projects: [
{
name: 'local-network',
use: { ...devices['Desktop Chrome'] },
},
],
webServer: [
{
command: 'PORT=3000 yarn serve',
url: 'http://localhost:3000',
reuseExistingServer: true,
timeout: 30_000,
},
{
command:
'aztec start --local-network --l1-rpc-urls http://localhost:8545',
url: 'http://localhost:8080/status',
reuseExistingServer: true,
timeout: 120_000,
},
],
});