-
Notifications
You must be signed in to change notification settings - Fork 5k
chore(line): report pause #38717
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore(line): report pause #38717
Conversation
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
| this.screen.stdout.write(`\u001B[1A\u001B[2K`); | ||
| } | ||
| this.writeLine(); | ||
| for (const error of formatResultFailure(this.screen, test, { ...result, errors: newErrors }, ' ')) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- I don't understand why
this.epilogue()won't print all the errors anyway. - (just an idea) we can mark errors with some symbol to avoid double-printing them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we're passing false to this.epilogue(), so it doesn't print any errors at all. All errors are printed during onTestEnd.
| this._printedErrorCounts.set(result, result.errors.length); | ||
|
|
||
| if (result.errors.length > 0) { | ||
| const errorHeader = this.formatTestHeader(test, { indent: ' ', index: ++this._failures }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we can use a helper in base.ts, something like formatSingleResult(), that will include everything except for Paused .... Press Ctrl+C to end line.
Co-authored-by: Dmitry Gozman <dgozman@gmail.com> Signed-off-by: Simon Knott <info@simonknott.de>
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
| updateSourceMethod: takeFirst(configCLIOverrides.updateSourceMethod, userConfig.updateSourceMethod, 'patch'), | ||
| version: require('../../package.json').version, | ||
| workers: resolveWorkers(takeFirst(configCLIOverrides.debug ? 1 : undefined, configCLIOverrides.workers, userConfig.workers, '50%')), | ||
| workers: resolveWorkers(takeFirst((configCLIOverrides.debug || configCLIOverrides.pause) ? 1 : undefined, configCLIOverrides.workers, userConfig.workers, '50%')), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Given that debug implies pause, we can just check for pause here?
| private _failures = 0; | ||
| private _lastTest: TestCase | undefined; | ||
| private _didBegin = false; | ||
| private _printedErrorCounts = new Map<TestResult, number>(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this one.
| } | ||
|
|
||
| for (const error of result.errors) { | ||
| const reportedIndex = (result as any)[kReportedSymbol] || 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's make this an explicit call, something like markErrorsAsReported(result), to avoid surprises in the future.
Test results for "tests 1"7 failed 4 flaky34458 passed, 699 skipped Merge workflow run. |
Test results for "MCP"1 failed 2821 passed, 116 skipped Merge workflow run. |
No description provided.