Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.
TypeScript automationchromechromiume2e-testingelectronend-to-end-testingfirefoxjavascriptplaywrighttesttest-automationtestingtesting-toolswebwebkit
docs: improve `test.describe.configure()` (#18705)
Dmitry Gozman6d456d30dc19
diff --git a/docs/src/test-api/class-test.md b/docs/src/test-api/class-test.mdindex 82a467c29a..fe277d4347 100644--- a/docs/src/test-api/class-test.md+++ b/docs/src/test-api/class-test.md@@ -343,17 +343,17 @@ test('runs first', async ({ page }) => {});test('runs second', async ({ page }) => {});```-Configuring retries and timeout:+Configuring retries and timeout for each test:```js tab=js-js-// All tests in the file will be retried twice and have a timeout of 20 seconds.+// Each test in the file will be retried twice and have a timeout of 20 seconds.test.describe.configure({ retries: 2, timeout: 20_000 });test('runs first', async ({ page }) => {});test('runs second', async ({ page }) => {});``````js tab=js-ts-// All tests in the file will be retried twice and have a timeout of 20 seconds.+// Each test in the file will be retried twice and have a timeout of 20 seconds.test.describe.configure({ retries: 2, timeout: 20_000 });test('runs first', async ({ page }) => {});test('runs second', async ({ page }) => {});@@ -363,14 +363,20 @@ test('runs second', async ({ page }) => {});* since: v1.10- `mode` <[TestMode]<"parallel"|"serial">>+Execution mode. Learn more about the execution modes [here](../test-parallel.md).+### option: Test.describe.configure.retries* since: v1.28- `retries` <[int]>+The number of retries for each test.+### option: Test.describe.configure.timeout* since: v1.28- `timeout` <[int]>+Timeout for each test in milliseconds. Overrides [`property: TestProject.timeout`] and [`property: TestConfig.timeout`].+## method: Test.describe.fixme* since: v1.25diff --git a/packages/playwright-test/types/test.d.ts b/packages/playwright-test/types/test.d.tsindex 6410d1a052..b8f6c5f6c0 100644--- a/packages/playwright-test/types/test.d.ts+++ b/packages/playwright-test/types/test.d.ts@@ -2123,10 +2123,10 @@ export interface TestType<TestArgs extends KeyValue, WorkerArgs extends KeyValue* test('runs second', async ({ page }) => {});* ```*- * Configuring retries and timeout:+ * Configuring retries and timeout for each test:** ```js- * // All tests in the file will be retried twice and have a timeout of 20 seconds.+ * // Each test in the file will be retried twice and have a timeout of 20 seconds.* test.describe.configure({ retries: 2, timeout: 20_000 });* test('runs first', async ({ page }) => {});* test('runs second', async ({ page }) => {});