Skip to content

Conversation

@hashtagchris
Copy link
Contributor

@hashtagchris hashtagchris commented Nov 26, 2020

Removing jest.spyOn(DownloadHttpClient.prototype, 'pipeResponseToFile') from the download artifact tests, and using a readable stream object to test pipeResponseToFile. Also verifying the destination file size on disk.

This is set up for a follow-up PR with new test cases for truncated responses, #652.

Copy link
Contributor

@yacaovsnc yacaovsnc left a comment

Choose a reason for hiding this comment

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

LGTM. Thanks for adding the check for file length.

@hashtagchris hashtagchris merged commit ff43080 into main Nov 30, 2020
@hashtagchris hashtagchris deleted the hashtagchris-test-pipeResponseToFile branch November 30, 2020 17:12
at-wat pushed a commit to at-wat/actions-toolkit that referenced this pull request Aug 31, 2023
…#651)

* Remove spyon, use readable stream to test pipeResponseToFile

* Check file contents
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.

3 participants