npm ls jest or npm ls react-scripts (if you haven’t ejected): jest@29.5.0, ts-jest@29.1.0
your vscode-jest settings if customized:
jest.jestCommandLine? : yes
jest.autoRun? : no
anything else that you think might be relevant? : no
i am using belows option
"jest.virtualFolders": [
{"name": "unit-tests", "jestCommandLine": "npm run test:unit --"},
{"name": "e2e-tests", "jestCommandLine": "npm run test:e2e --"}
]
Operating system: : mac
Prerequisite
are you able to run jest test from the command line? : nope
how do you run your tests from the command line? :
i do like below
cross-env NODE_ENV=dev NODE_OPTIONS=--experimental-vm-modules npx jest --config jest-e2e.json --colors
Steps to Reproduce
[fill]
Relevant Debug Info
[fill]
Expected Behavior
i have 2 tests.
✓ should sign out (20 ms)
✓ should sign out with users real remote ip
but i would like to onoly works should sign out, but works two.
and below is all command (can i check on jest terminal by extension)
cross-env NODE_ENV=dev NODE_OPTIONS=--experimental-vm-modules npx jest --config jest-e2e.json --colors "--testLocationInResults" "--json" "--useStderr" "--outputFile" "/var/folders/nk/31mhwxz50_j2b2_s_pm0j2q00000gn/T/jest_runner_e2e_tests_501_2.json" "--testNamePattern" "User Signout API Test /api/user/sign-out should sign out" "--coverage" "--reporters" "default" "--reporters" "/Users/..../.vscode/extensions/orta.vscode-jest-6.0.1/out/reporter.js" "--colors" "--watchAll=false" "--testPathPattern" "/Users//..../Documents/...../src/auth/__test/user/signout/controller\.e2e-spec\.ts"
Here i can check, testNamePattern is not regex and just plain text.
(--testNamePattern" "User Signout API Test /api/user/sign-out should sign out")
the regex(/should sign out/) matchs to (should sign out with users real remote ip) and (should sign out).
i thinks the text should be like to "regex(/^should sign out$/"
Actual Behavior
[fill]
The fastest (and the most fun) way to resolve the issue is to submit a pull-request yourself. If you are interested, feel free to check out the contribution guide, we look forward to seeing your PR...
The testNamePattern passes the "full name", i.e. from the describe blocks all the way down to the test. we don't need the "^," but you are right that we could append a "$" to end the pattern.
Environment
vscode-jest version
: v6.0.1node -v
: 16.0npm -v
oryarn --version
: npm 8.5.5npm ls jest
ornpm ls react-scripts
(if you haven’t ejected): jest@29.5.0, ts-jest@29.1.0Prerequisite
Steps to Reproduce
[fill]
Relevant Debug Info
[fill]
Expected Behavior
i have 2 tests. ✓ should sign out (20 ms) ✓ should sign out with users real remote ip
but i would like to onoly works should sign out, but works two. and below is all command (can i check on jest terminal by extension) cross-env NODE_ENV=dev NODE_OPTIONS=--experimental-vm-modules npx jest --config jest-e2e.json --colors "--testLocationInResults" "--json" "--useStderr" "--outputFile" "/var/folders/nk/31mhwxz50_j2b2_s_pm0j2q00000gn/T/jest_runner_e2e_tests_501_2.json" "--testNamePattern" "User Signout API Test /api/user/sign-out should sign out" "--coverage" "--reporters" "default" "--reporters" "/Users/..../.vscode/extensions/orta.vscode-jest-6.0.1/out/reporter.js" "--colors" "--watchAll=false" "--testPathPattern" "/Users//..../Documents/...../src/auth/__test/user/signout/controller\.e2e-spec\.ts"
Here i can check, testNamePattern is not regex and just plain text. (--testNamePattern" "User Signout API Test /api/user/sign-out should sign out") the regex(/should sign out/) matchs to (should sign out with users real remote ip) and (should sign out).
i thinks the text should be like to "regex(/^should sign out$/"
Actual Behavior
[fill]
The fastest (and the most fun) way to resolve the issue is to submit a pull-request yourself. If you are interested, feel free to check out the contribution guide, we look forward to seeing your PR...