Add more structured output for tests#626
Merged
aeisenberg merged 1 commit intogithub:mainfrom Nov 9, 2020
Merged
Conversation
75a2ccb to
4b376ed
Compare
adityasharad
reviewed
Nov 9, 2020
Contributor
adityasharad
left a comment
There was a problem hiding this comment.
Should be good to go after a rebase.
| const state = event.pass | ||
| ? 'passed' | ||
| : event.messages?.length | ||
| ? 'errored' |
Contributor
There was a problem hiding this comment.
Would failed due to errors or failed to run be more meaningful for the user? I had to think about the difference between 'errored' and 'failed' for a moment.
Contributor
Author
There was a problem hiding this comment.
That won't work. state is a property of the TestEvent interface and only allows 'running' | 'passed' | 'failed' | 'skipped' | 'errored'. The hope is that the messages will be more explicit as to what happened.
Contributor
There was a problem hiding this comment.
Oh fair enough. We can consider having more detail in the way message is constructed below, but no need to block this PR.
f0ad23b to
4d24f85
Compare
adityasharad
approved these changes
Nov 9, 2020
The diff and the errors were always available, but they were not being sent to the output. Additionally, make sure to send output to both the test explorer log and the codeql test log.
4d24f85 to
11517ee
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The diff and the errors were always available, but they were not being sent to the output.
Additionally, make sure to send output to both the test explorer log and the codeql test log.
Resolves #582.
Checklist
@github/docs-content-dsphas been cc'd in all issues for UI or other user-facing changes made by this pull request.