Browse Source

fix: default list reporter should dump stderr to stderr (#11351)

This is consistent with all other reporters we have in place.
pull/11353/head
Andrey Lushnikov 2 weeks ago
committed by GitHub
parent
commit
6f932fcb4a
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      installation-tests/installation-tests.sh
  2. 2
      packages/playwright-test/src/reporters/list.ts

2
installation-tests/installation-tests.sh

@ -633,7 +633,7 @@ function test_playwright_test_stacks_should_work {
copy_test_scripts
echo "Running playwright test"
OUTPUT=$(DEBUG=pw:api npx playwright test -c . failing.spec.js || true)
OUTPUT=$(DEBUG=pw:api npx playwright test -c . failing.spec.js 2>&1 || true)
if [[ "${OUTPUT}" != *"expect.toHaveText started"* ]]; then
echo "ERROR: missing 'expect.toHaveText started' in the output"
exit 1

2
packages/playwright-test/src/reporters/list.ts

@ -67,7 +67,7 @@ class ListReporter extends BaseReporter {
override onStdErr(chunk: string | Buffer, test?: TestCase, result?: TestResult) {
super.onStdErr(chunk, test, result);
this._dumpToStdio(test, chunk, process.stdout);
this._dumpToStdio(test, chunk, process.stderr);
}
onStepBegin(test: TestCase, result: TestResult, step: TestStep) {

Loading…
Cancel
Save