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
pnpm install
# you can switch environment between 'node' (default value) and 'jsdom'
pnpm test
# in 'node' environment:
#
# modify any code in node_modules
# - the test is not re-run
# in 'jsdom' environment:
#
# modify code in node_modules/foo-cjs/index.js or node_modules/foo-esm/index.js
# - when you first time modify it, the test is not re-run
# - when you further modify it, the test is re-run
#
# modify code in node_modules/foo-cjs/foo.js or node_modules/foo-esm/foo.js
# - the test is not re-run
The expected behavior is that the test is always re-run when any code in node_modules/foo-cjs and node_modules/foo-esm is modified whatever the environment is.
Describe the bug
From what I tried so far, the
watchExclude
for code innode_modules
option doesn't work when:node
.jsdom
andMore discussion info: #4772 (reply in thread)
Reproduction
https://github.com/Jinjiang/reproductions/tree/vitest-watch-node_modules-20231220
The expected behavior is that the test is always re-run when any code in
node_modules/foo-cjs
andnode_modules/foo-esm
is modified whatever the environment is.System Info
Used Package Manager
pnpm
Validations
The text was updated successfully, but these errors were encountered: