-
Notifications
You must be signed in to change notification settings - Fork 25
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
feat!: use streams to refactor writeResultFiles #352
Conversation
@W-15135036@ refactor to use streams while producing results after tests are complete
…phale/W-15135036-streams # Conflicts: # src/reporters/tapReporter.ts # src/tests/testService.ts
} | ||
); | ||
|
||
this.push('\n\n'); |
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.
probably a dumb q, but does this cover all OS newlines?
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'll fix this
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.
This make sense.
Two suggestions
- Ensure we do a major version bump when this is merged
- Probably would be good to define test plan that covers both the small and large responses and the different code flows we need to cover.
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 tested it from plugin-apex and vsce. Looks good to me! Thanks a lot for the change!
This reverts commit 9c2123d. # Conflicts: # src/streaming/codeCoverageStringifyStream.ts # src/streaming/streamingClient.ts # src/streaming/testResultStringifyStream.ts # src/tests/asyncTests.ts # test/streaming/jsonStringifyStream.test.ts
* chore: wip * feat: refactor results to use streams @W-15135036@ refactor to use streams while producing results after tests are complete * chore: add human report transform and stream * chore: cleanup after merging main * refactor: create narrowing functions * chore: add elapsed time decorator to streamingClient * chore: replace hardcoded newlines with os.EOL
I modifies the testService.writeFiles to use streams to produce the requested output formats on disk.
This is necessary to handle very large test results that were causing string length violations when running
JSON.stringify for json results.
@W-15135036@
AC:
Should be no changes to results produced by tests.