refactor(storage): gaxios migration system test fix#8
refactor(storage): gaxios migration system test fix#8thiyaguk09 wants to merge 12 commits intostorage-node-18from
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the Google Cloud Storage client to use the /storage/v1 prefix for API endpoints and ensures Content-Type: application/json headers are explicitly set for POST requests. It also includes significant updates to system tests, such as skipping problematic public access tests, improving error handling in cleanup routines, and ensuring Node 18 compatibility in the transport layer. Review feedback identified a potential TypeError in getServiceAccount due to missing optional chaining, a bug in a test timeout callback that would cause tests to hang, and a potential type mismatch in error status assertions within the system tests.
| const ms = Math.pow(2, retries) * 1000 + Math.random() * 2000; | ||
| console.info(`retrying "${title}" in ${ms}ms`); | ||
| setTimeout(done(), ms); | ||
| setTimeout(() => done, ms); |
There was a problem hiding this comment.
The setTimeout call is passing an arrow function that returns the done function but does not execute it. This will cause the test to hang or timeout because the done callback is never invoked. It should be changed to pass the done function directly so it can be executed when the timer expires.
| setTimeout(() => done, ms); | |
| setTimeout(done, ms); |
957daf5 to
70a0132
Compare
|
/gemini_review |
Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:
Fixes #<issue_number_goes_here> 🦕