Skip to content

fix(reporter): use Screen in html reporter for PLAYWRIGHT_FORCE_TTY support#39776

Open
yury-s wants to merge 3 commits intomicrosoft:mainfrom
yury-s:fix-39766
Open

fix(reporter): use Screen in html reporter for PLAYWRIGHT_FORCE_TTY support#39776
yury-s wants to merge 3 commits intomicrosoft:mainfrom
yury-s:fix-39766

Conversation

@yury-s
Copy link
Member

@yury-s yury-s commented Mar 19, 2026

Summary

  • Replace direct process.stdin.isTTY checks in the HTML reporter with terminalScreen.isTTY, which respects the PLAYWRIGHT_FORCE_TTY environment variable
  • Replace process.stdout.write in writeLine with terminalScreen.stdout.write for consistency

This fixes the regression introduced in #38044 where JetBrains IDEs (WebStorm, IntelliJ) stopped auto-opening the HTML report because their test runners don't set process.stdin.isTTY. Users can now set PLAYWRIGHT_FORCE_TTY=1 to work around this.

Fixes #39766

@yury-s yury-s changed the title fix(reporter): use terminalScreen in html reporter for PLAYWRIGHT_FORCE_TTY support fix(reporter): use Screen in html reporter for PLAYWRIGHT_FORCE_TTY support Mar 19, 2026
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@pavelfeldman
Copy link
Member

Looks dangerous as it will block users that opted into PLAYWRIGHT_FORCE_TTY for non-TTY CI as per our recommendation.

@github-actions

This comment has been minimized.

@github-actions
Copy link
Contributor

Test results for "tests 1"

6 flaky ⚠️ [chromium-library] › library/trace-viewer.spec.ts:1223 › should display language-specific locators `@ubuntu-22.04-chromium-tip-of-tree`
⚠️ [chromium-library] › library/trace-viewer.spec.ts:1223 › should display language-specific locators `@chromium-ubuntu-22.04-arm-node20`
⚠️ [chromium-library] › library/capabilities.spec.ts:95 › should play audio @smoke `@chromium-ubuntu-22.04-node20`
⚠️ [chromium-library] › library/trace-viewer.spec.ts:1223 › should display language-specific locators `@chromium-ubuntu-22.04-node20`
⚠️ [chromium-library] › library/trace-viewer.spec.ts:1223 › should display language-specific locators `@chromium-ubuntu-22.04-node22`
⚠️ [webkit-library] › library/screencast.spec.ts:75 › start reuses existing screencast when video recording is running `@webkit-ubuntu-22.04-node20`

38815 passed, 845 skipped


Merge workflow run.

@github-actions
Copy link
Contributor

Test results for "MCP"

1 failed
❌ [msedge] › mcp/dashboard.spec.ts:23 › should show browser session chip @mcp-windows-latest

5493 passed, 343 skipped


Merge workflow run.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Regression]: HTML reporter does not open anymore after executing test through WebStorm/Intellij test runner

2 participants