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

Use classes to better handle tests #881

Merged
merged 1 commit into from
Oct 6, 2023
Merged

Conversation

j0k3r
Copy link
Member

@j0k3r j0k3r commented Sep 27, 2023

Because of recent changes from the Octokit library (relying on Node internal fetch), we can't use nock anymore during tests. We must now pass a custom fetch to the Octokit class to mock request. To do that, we can no longer only use handler with all the code inside it, but use classes. It's also more clean :)

Because of recent changes from the Octokit library (relying on Node internal fetch), we can't use `nock` anymore during tests. We must now pass a custom `fetch` to the Octokit class to mock request.
To do that, we can no longer only use `handler` with all the code inside it, but use classes. It's also more clean :)
@j0k3r j0k3r force-pushed the fix/better-handle-fetch-mock branch from da1e5ff to 1607075 Compare October 6, 2023 14:28
@j0k3r j0k3r merged commit e3f3ed3 into master Oct 6, 2023
2 checks passed
@j0k3r j0k3r deleted the fix/better-handle-fetch-mock branch October 6, 2023 14:29
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.

1 participant