You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
and my tests fail with error SyntaxError: The requested module '/node_modules/.vite/deps/vue-i18n.js?t=1727382327247&v=ec0aa5b1' does not provide an export named 'useI18n'
which is strange because I am providing it in the mock above, and even if mock wouldn't work real import does have it.
I have opened the test in headed mode in ui and inspected the network tab.
Request to http://localhost:5173/node_modules/.vite/deps/vue-i18n.js?t=1727382794575&v=ec0aa5b1
contains this content
Describe the bug
For some reason mocked module in browser mode returns wrong exports
Reproduction
I am trying to mock some modules in browser mode
like this
and my tests fail with error
SyntaxError: The requested module '/node_modules/.vite/deps/vue-i18n.js?t=1727382327247&v=ec0aa5b1' does not provide an export named 'useI18n'
which is strange because I am providing it in the mock above, and even if mock wouldn't work real import does have it.
I have opened the test in headed mode in ui and inspected the network tab.
Request to
http://localhost:5173/node_modules/.vite/deps/vue-i18n.js?t=1727382794575&v=ec0aa5b1
contains this content
which is the content of the mock for
ui-helpers
I am kinda puzzled here if I am doing something wrong with mocking?
System Info
Used Package Manager
npm
Validations
The text was updated successfully, but these errors were encountered: