microsoft / microsoft/vscode-test
Using mocha.report in .vscode-test.js results in "Test process exited unexpectedly" error on "Run Tests"
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 316
- Forks
- 73
- Avg merge
- 1d 6h
- Merged PRs (30d)
- 3
Description
To Reproduce:
- Follow https://code.visualstudio.com/api/get-started/your-first-extension to create a simple, unbundled TypeScript-based extension
- Follow https://code.visualstudio.com/api/working-with-extensions/testing-extension to set up
vscode-test - Select
src/test/extension.test.tsand choose Run Tests from the context menu - This shows a successfully executing Sample test in the TEST RESULTS window
- Edit
.vscode-test.mjsby adding the followingmocha: { reporter: "Spec" } - Select
src/test/extension.test.tsagain and choose Run Tests from the context menu - This shows an error for Sample test
Test process exited unexpectedly, view output
In particular, this masks any real test failures. All tests are shown as failures because of this.
Running with a configured mocha.reporter on the command-line (via pnpm test in my case) works as expected.
Versions:
- "@vscode/test-cli": "^0.0.10",
- "@vscode/test-electron": "^2.5.
- Version: 1.101.2
- Commit: 2901c5ac6db8a986a5666c3af51ff804d05af0d4
- Date: 2025-06-24T20:27:15.391Z
- Electron: 35.5.1
- ElectronBuildId: 11727614
- Chromium: 134.0.6998.205
- Node.js: 22.15.1
- V8: 13.4.114.21-electron.0
- OS: Linux x64 6.11.0-28-generic snap
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the issue with the sample unbundled TypeScript extension, editing .vscode-test.mjs to add the Mocha reporter and running Run Tests. Compare this with the working pnpm test command; done means configured reporters work in Run Tests without turning every test into an unexpected process failure.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- node.js, typescript
- Domain
- testing-qa
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100