Replies: 2 comments 1 reply
-
|
Hi, @segamiken. Is that override handler being hit at all? When something doesn't get mocked as expected, always follow the Debugging runbook. Please do that and share with me what you find. |
Beta Was this translation helpful? Give feedback.
-
|
Thank you for your help! As a premise, the mock handler override works fine when using I went through the Debugging Runbook and performed the necessary steps, but both environments seem to be set up correctly. The root cause is still unclear... Here are the results of my debugging: step-1-verify-setup
step-2-verify-handler
|
Beta Was this translation helpful? Give feedback.




Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Detail
When using nuxt/test-utils together with msw, even if I override the handler using
server.usein the test file, for some reason the data from the default handler is still being rendered.There are some related issues on the
nuxt/test-utilsside as well, but does anyone have any idea what might be causing this?nuxt/test-utils#1222
Reproduction repository
This test doesn't pass.
https://github.com/AlexanderForm1/nuxt-msw-override
Reproduction steps
npm installnpx vitestBeta Was this translation helpful? Give feedback.
All reactions