Skip to content

fix(reporter): spread AggregateError sub-errors into testInfo.errors#40925

Open
Skn0tt wants to merge 1 commit into
microsoft:mainfrom
Skn0tt:fix-40856
Open

fix(reporter): spread AggregateError sub-errors into testInfo.errors#40925
Skn0tt wants to merge 1 commit into
microsoft:mainfrom
Skn0tt:fix-40856

Conversation

@Skn0tt
Copy link
Copy Markdown
Member

@Skn0tt Skn0tt commented May 20, 2026

Summary

  • Spread AggregateError.errors[] (any error exposing an errors array) into separate entries on testInfo.errors, pre-order DFS, symmetric with how soft assertion failures appear.
  • Reporters get this for free — no public API changes.

Fixes #40856

@Skn0tt Skn0tt requested a review from dgozman May 20, 2026 12:17
@github-actions
Copy link
Copy Markdown
Contributor

Test results for "MCP"

1 failed
❌ [msedge] › mcp/dashboard.spec.ts:159 › save recording streams WebM bytes to the chosen file @mcp-windows-latest-msedge

7180 passed, 1113 skipped


Merge workflow run.

@github-actions
Copy link
Copy Markdown
Contributor

Test results for "tests 1"

4 flaky ⚠️ [chromium-library] › library/screencast.spec.ts:28 › screencast.start delivers frames via onFrame callback `@ubuntu-22.04-chromium-tip-of-tree`
⚠️ [chromium-library] › library/video.spec.ts:682 › screencast › should capture full viewport on hidpi `@chromium-ubuntu-22.04-arm-node20`
⚠️ [chromium-library] › library/popup.spec.ts:261 › should not throw when click closes popup `@chromium-ubuntu-22.04-node24`
⚠️ [chromium-library] › library/video.spec.ts:647 › screencast › should capture full viewport `@chromium-ubuntu-22.04-node20`

42034 passed, 850 skipped


Merge workflow run.

this._tracing.appendForError(serialized);
const visit = (error: Error | unknown) => {
const serialized = testInfoError(error);
const step: TestStepInternal | undefined = typeof error === 'object' ? (error as any)?.[stepSymbol] : undefined;
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the step should be gathered only once, for the top-level error. Inner errors are unlikely to have the step attached.

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.

[Bug]: AggregateError.errors[] sub-errors are invisible in reporter output — only the top-level message is serialized

2 participants