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

Replace fetch-mock dependency with Sinon mocks #8794

Merged
merged 1 commit into from
Jul 5, 2024

Conversation

robertknight
Copy link
Member

The window.fetch API is simple enough that we can mock it with the same Sinon mocks that we use in the rest of the code. This gives us one less dependency to manage and also aligns with how we do fetch mocking in other apps.

See also https://hypothes-is.slack.com/archives/C1M8NH76X/p1720166259836159 for context.

The `window.fetch` API is simple enough that we can mock it with the same Sinon
mocks that we use in the rest of the code. This gives us one less dependency to
manage and also aligns with how we do `fetch` mocking in other apps.
Copy link
Contributor

@acelaya acelaya left a comment

Choose a reason for hiding this comment

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

Wow! A ton of dependencies we are getting rid of this way 💪🏼

@robertknight robertknight merged commit 0655caa into main Jul 5, 2024
9 checks passed
@robertknight robertknight deleted the replace-fetch-mock branch July 5, 2024 08:35
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.

None yet

2 participants