Replies: 1 comment 5 replies
-
Figured it out... the |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hey there, I'm really puzzled about this one... I've followed all the docs, tried writing and re-writing the code many times in case I made some mistake, and tried to follow advice from a few posts I found about similar issues.
But I can't figure out why when I try to add a new handler with server.use it's not working.
The weirdest part is that if I do
printHandlers
, I see my new handler (first on the top of the printed list) but using console log I see the original one is being executed every time...Here's the setup I have:
on setupJest.js which I add through
setupFilesAfterEnv
in jest.config.js I have thisthen on my test file:
And finally, when using printHandlers, I see this at the top of the list (being printed first I guess)
My wild guess is that URLs with wildcards are not properly overridden maybe?
The other weird thing is that a similar case but using
worker.use
does work properly, but not for server.useIdeas on what could I be doing wrong here?
Let me know if you need any more info, and thanks!
Beta Was this translation helpful? Give feedback.
All reactions