Repository navigation
Report active tests on browser-wasm - #10129
Conversation
Emit durable, deduplicated test-start lines from the browser output device and honor the existing progress switches. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 68fe177a-162b-4580-9300-3466dcbb3f2b
There was a problem hiding this comment.
Pull request overview
Adds durable active-test progress output for browser-wasm runs to help diagnose hangs.
Changes:
- Emits deduplicated
running <test>messages and clears them on completion. - Honors
--progressand--no-progress. - Adds unit and browser-wasm acceptance coverage.
Show a summary per file
| File | Description |
|---|---|
TerminalTestReporterCommandLineOptionsProviderTests.cs |
Tests progress-option precedence and defaults. |
SimplifiedConsoleOutputDeviceTests.cs |
Tests progress emission, suppression, deduplication, and retries. |
BrowserWasmExecutionTests.cs |
Verifies active-test output under Node. |
TerminalOutputDevice.Initialization.cs |
Reuses centralized progress-option evaluation. |
TerminalTestReporterCommandLineOptionsProvider.cs |
Adds shared progress enablement logic. |
SimplifiedConsoleOutputDeviceBase.cs |
Emits keyed active-test progress messages. |
OutputDeviceManager.cs |
Supplies command-line options to the browser device. |
BrowserOutputDevice.cs |
Enables browser progress according to CLI options. |
InternalAPI.Unshipped.txt |
Tracks new common internal members. |
Review details
- Files reviewed: 9/9 changed files
- Comments generated: 1
- Review effort level: Medium
This comment has been minimized.
This comment has been minimized.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 68fe177a-162b-4580-9300-3466dcbb3f2b
There was a problem hiding this comment.
Note
🤖 Automated review by GitHub Copilot. Generated by the Expert Code Review workflow. To request a follow-up action, reply by tagging @copilot directly.
Review Summary
Clean PR. The implementation is well-structured: it reuses the existing ProgressMessageOutputDeviceData deduplication infrastructure, correctly gates progress behind DisplayActiveTestProgress, and the refactored IsProgressEnabled helper consolidates previously duplicated logic.
| Dimension | Verdict |
|---|---|
| 1. Algorithmic Correctness | ✅ Clean — early return for in-progress avoids double-counting; testCompleted flag + null-message removal enables re-reporting after completion |
| 2. Threading & Concurrency | ✅ Clean — all mutable state access is under _asyncMonitor lock |
| 3. Security & IPC | N/A |
| 4. Public API & Binary Compat | ✅ Clean — new members are internal/protected virtual on internal class; declared in InternalAPI.Unshipped.txt |
| 5. Performance & Allocations | ✅ Minor: interpolated string $"running {DisplayName}" allocates per in-progress event, but this is a low-frequency browser-only path — acceptable |
| 6. Cross-TFM Compat | ✅ Clean — gated behind #if NET7_0_OR_GREATER |
| 7–22 | ✅ Clean or N/A |
No blocking or major issues found. Good test coverage with unit tests for dedup, opt-in/opt-out, and re-report-after-completion scenarios, plus integration test validation.
🧪 Test quality grade — PR #10129
This advisory comment was generated automatically. Grades are heuristic Warning Firewall blocked 1 domainThe following domain was blocked by the firewall during workflow execution:
network:
allowed:
- defaults
- "awmgmcpg"See Network Configuration for more information.
|
Browser-wasm runs can block the single WASM thread synchronously, leaving users with no indication of which test is hanging. This change emits an immediate, durable
running <test>line before each test begins.The browser output device reuses MTP's keyed progress-message semantics to deduplicate repeated in-progress updates by test UID and clears the key when the test completes so retries remain visible. It honors the existing
--progress offand--no-progresscontrols without enabling the unsupported terminal reporter or changing CLI help.Focused unit coverage verifies progress options, UID deduplication, suppression, and retry behavior. Browser-wasm acceptance coverage verifies start lines end to end under Node.
Related to #2196, especially issue comment 5032231745.