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

test: migrate from nock to MSW #904

Merged
merged 4 commits into from
Aug 22, 2023
Merged

Conversation

kanadgupta
Copy link
Member

@kanadgupta kanadgupta commented Aug 22, 2023

🚥 Slack thread

🧰 Changes

This PR moves us our HTTP mocking library from nock to msw for several reasons:

It took a bit for it to grow on me since I'm used to nock's batteries-included approach but its API has grown on me 😌

🧬 QA & Testing

I'm seeing some unrelated PHP build errors, but it appears the Node tests are passing so we should be good to go if folks are cool with us using this package!

@kanadgupta kanadgupta marked this pull request as ready for review August 22, 2023 21:09
@kanadgupta kanadgupta requested review from erunion and a team August 22, 2023 21:09
@kanadgupta kanadgupta added the refactor Issues about tackling technical debt label Aug 22, 2023

import * as crypto from 'crypto';
import { createServer } from 'http';

import chai, { expect } from 'chai';
import chaiAssertionsCount from 'chai-assertions-count';
Copy link
Member Author

Choose a reason for hiding this comment

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

had to bring this package in since mocha/chai doesn't have an equivalent for expect.assertions 🙃

@kanadgupta kanadgupta merged commit 3caddac into main Aug 22, 2023
@kanadgupta kanadgupta deleted the test/migrate-from-nock-to-msw branch August 22, 2023 23:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
refactor Issues about tackling technical debt
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants