Skip to content

Commit

Permalink
fix: enrich error context around test not found
Browse files Browse the repository at this point in the history
  • Loading branch information
zxch3n committed Aug 30, 2022
1 parent bc2654f commit 443ed52
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/runHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -180,8 +180,9 @@ function determineWorkspaceForTestItems(collection: readonly vscode.TestItem[] |
type Mode = 'debug' | 'run' | 'update'
const TEST_NOT_FOUND_MESSAGE
= 'Test result not found. \r\n'
+ 'Did you set `vitest.commandLine` to `run` mode? (This extension requires `watch` mode to get the results from Vitest api)\r\n'
+ 'Are there tests with the same name?\r\n'
+ 'Can you run vitest successfully on this file? Does it need custom option to run?'
+ 'Can you run vitest successfully on this file? Does it need custom option to run?\r\n'
async function runTest(
ctrl: vscode.TestController,
runner: TestRunner | undefined,
Expand Down

0 comments on commit 443ed52

Please sign in to comment.