-
Notifications
You must be signed in to change notification settings - Fork 241
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
Mock a post request with data and query params #88
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Firstly: Thanks for the great tool!
Now for my issue:
How can I mock a post request which checks both data and query params?
The production code looks like this:
The tests I have
However the params don't seem to matter, I can leave them out, change them, the mock always returns the same data. If I change the body (managerId) then the mock does not return the data, which is what I expect.
How can I mock axios, so that the mocked data is only returned if URL matches, the query params match, and the data match?
Thanks
The text was updated successfully, but these errors were encountered: