The Vitest configuration needed to test a VS Code extension, as a value you
can merge instead of settings you have to know about.
Two things have to line up, and getting either wrong produces an error that
doesn't name its cause: vscode must resolve to a mock, and this kit must be
transformed by Vite rather than externalized, or its ownvscode imports
bypass that mock. See vscodeExtKitVitestConfig for the details.
The Vitest configuration needed to test a VS Code extension, as a value you can merge instead of settings you have to know about.
Two things have to line up, and getting either wrong produces an error that doesn't name its cause:
vscodemust resolve to a mock, and this kit must be transformed by Vite rather than externalized, or its ownvscodeimports bypass that mock. See vscodeExtKitVitestConfig for the details.