Skip to content
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

build: fix test for signal option so it works across Node.js versions #509

Merged
merged 1 commit into from
Aug 15, 2022

Conversation

timrogers
Copy link
Contributor

We test the signal option by passing in a value that isn't a signal and expecting fetch to throw an error.

An error is thrown, but our current assertion doesn't work in Node.js v18 because the error message has changed. This changes the assertion to work with the behaviour of Node v14, v16 and v18.

@ghost ghost added this to Inbox in JS Aug 15, 2022
@timrogers timrogers added the Type: Maintenance Any dependency, housekeeping, and clean up Issue or PR label Aug 15, 2022
@ghost ghost moved this from Inbox to Maintenance in JS Aug 15, 2022
test/request.test.ts Outdated Show resolved Hide resolved
We test the `signal` option by passing in a value that isn't a
signal and expecting `fetch` to throw an error.

An error is thrown, but our current assertion doesn't work in
Node.js v18 because the error message has changed. This changes
the assertion to work with the behaviour of Node v14, v16 and v18.
@timrogers timrogers merged commit 41808ab into master Aug 15, 2022
JS automation moved this from Maintenance to Done Aug 15, 2022
@timrogers timrogers deleted the timrogers/signal-test branch August 15, 2022 13:28
@github-actions
Copy link

🎉 This PR is included in version 6.2.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Maintenance Any dependency, housekeeping, and clean up Issue or PR
Projects
No open projects
JS
  
Done
Development

Successfully merging this pull request may close these issues.

None yet

2 participants