-
Notifications
You must be signed in to change notification settings - Fork 31
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No tests listed using tsx loader #250
Comments
I think I have some new findings but no solution yet. I am diving into the extension further I patched locally some things to see the messages exchanged between the worker loading the tests and the plugin process. This is the test model loaded and received here: {
"type": "suite",
"id": "undefined: ",
"label": "",
"children": [{
"type": "suite",
"id": "D:\\Dev\\mocha-test-explorer\\test\\rules.test.ts: Suite",
"label": "Suite",
"file": "D:\\Dev\\mocha-test-explorer\\test\\rules.test.ts",
"line": 0,
"children": [{
"type": "test",
"id": "D:\\Dev\\mocha-test-explorer\\test\\rules.test.ts: Suite Test",
"label": "Test",
"file": "D:\\Dev\\mocha-test-explorer\\test\\rules.test.ts",
"line": 1,
"skipped": false
}
]
}
]
}
The Suite ID and label made me worrying. But also afterwards this error is signaled as
This error clears out the test list loaded. Commenting out this signaling I see the tests. But executing them doesn't work. It just shows: |
I narrowed down the root cause. The
Those are then misinterpreted here breaking everything: vscode-mocha-test-adapter/src/core.ts Lines 129 to 157 in f519292
I could open a PR with a fix ensuring we only handle "own" events in the plugin. @hbenl Is this project still alive? I wonder as it looks rather dead: no code changes since a long time, PRs and issues not answered, and it currently doesn't build. |
I have the following setup and no tests are listed in the test explorer. Not sure what could be the cause and I had once a similar to same setup working and running. I lately upgraded Node.js so that could be related.
Files
.vscode/settings.json
tests/rules.test.ts
.mocharc.json
package.json
Running Tests
npm run test
Mocha Explorer Log
Environment
Node: v18.18.2
NPM: 9.1.3
VS Code: 1.83.1
Operating System: Windows 11 Pro 22H2
Test Explorer UI: v2.21.1
Mocha Test Explorer: v2.14.1
The text was updated successfully, but these errors were encountered: