Can cy.intercept be used for api mocking in vitest or jest #30188
krishnagkmit
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
So in my react app I have written unit and integration test using vitest and e2e test using cypress.
I want to mock apis for my test and cypress provides
cy.intercept
that works for e2e, but I also want to use these api mocks in my vitest and don’t want to install mock service provider (MSW) for the same job.so is it possible to use cy.intercept and if yes how?
Beta Was this translation helpful? Give feedback.
All reactions