Skip to content

Commit 50f22f1

Browse files
authored
docs: document config executing multiple times (#34576)
1 parent 311625b commit 50f22f1

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

docs/src/test-api/class-testproject.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,10 @@ Metadata that will be put directly to the test report serialized as JSON.
183183

184184
Project name is visible in the report and during test execution.
185185

186+
:::warning
187+
Playwright executes the configuration file multiple times. Do not dynamically produce non-stable values in your configuration.
188+
:::
189+
186190
## property: TestProject.snapshotDir
187191
* since: v1.10
188192
- type: ?<[string]>

packages/playwright/types/test.d.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -349,6 +349,10 @@ interface TestProject<TestArgs = {}, WorkerArgs = {}> {
349349

350350
/**
351351
* Project name is visible in the report and during test execution.
352+
*
353+
* **NOTE** Playwright executes the configuration file multiple times. Do not dynamically produce non-stable values in
354+
* your configuration.
355+
*
352356
*/
353357
name?: string;
354358

0 commit comments

Comments
 (0)