Skip to content

Commit

Permalink
fix(testrunner): attribute unhandle promise reject to a single worker (
Browse files Browse the repository at this point in the history
…#1491)

When there is a single worker, we are almost sure the error originated in that worker. Attributing it helps with context by showing last run tests.
  • Loading branch information
dgozman committed Mar 23, 2020
1 parent de0a2d1 commit 6390645
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion utils/testrunner/TestRunner.js
Expand Up @@ -411,7 +411,7 @@ class TestPass {
if (error) {
if (error.stack)
await this._runner._sourceMapSupport.rewriteStackTraceWithSourceMaps(error);
this._result.addError(message, error);
this._result.addError(message, error, this._workers.length === 1 ? this._workers[0] : null);
}
}

Expand Down

0 comments on commit 6390645

Please sign in to comment.