Skip to content

Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.

fix: remove unused TestInfo.stdout/stderr (#29076)

Max Schmittdb00aa73058f
diff --git a/docs/src/test-api/class-testinfo.md b/docs/src/test-api/class-testinfo.md
index b8b492efbc..3dca7942e4 100644
--- a/docs/src/test-api/class-testinfo.md
+++ b/docs/src/test-api/class-testinfo.md
@@ -416,18 +416,6 @@ test.afterEach(async ({}, testInfo) => {
});
```
-## property: TestInfo.stderr
-* since: v1.10
-- type: <[Array]<[string]|[Buffer]>>
-
-Output written to `process.stderr` or `console.error` during the test execution.
-
-## property: TestInfo.stdout
-* since: v1.10
-- type: <[Array]<[string]|[Buffer]>>
-
-Output written to `process.stdout` or `console.log` during the test execution.
-
## property: TestInfo.timeout
* since: v1.10
- type: <[int]>
diff --git a/packages/playwright/src/worker/testInfo.ts b/packages/playwright/src/worker/testInfo.ts
index c4777355d7..37a523c0ab 100644
--- a/packages/playwright/src/worker/testInfo.ts
+++ b/packages/playwright/src/worker/testInfo.ts
@@ -88,8 +88,6 @@ export class TestInfoImpl implements TestInfo {
readonly annotations: Annotation[] = [];
readonly attachments: TestInfo['attachments'] = [];
status: TestStatus = 'passed';
- readonly stdout: TestInfo['stdout'] = [];
- readonly stderr: TestInfo['stderr'] = [];
snapshotSuffix: string = '';
readonly outputDir: string;
readonly snapshotDir: string;
diff --git a/packages/playwright/types/test.d.ts b/packages/playwright/types/test.d.ts
index f2bc93ad3c..1bdb8c341f 100644
--- a/packages/playwright/types/test.d.ts
+++ b/packages/playwright/types/test.d.ts
@@ -2307,16 +2307,6 @@ export interface TestInfo {
*/
status?: "passed"|"failed"|"timedOut"|"skipped"|"interrupted";
- /**
- * Output written to `process.stderr` or `console.error` during the test execution.
- */
- stderr: Array<string|Buffer>;
-
- /**
- * Output written to `process.stdout` or `console.log` during the test execution.
- */
- stdout: Array<string|Buffer>;
-
/**
* Test id matching the test case id in the reporter API.
*/