vitest-dev / vscode

VS Code extension for Vitest
https://vitest.dev/vscode
MIT License
736 stars 83 forks source link

Running test on the `packages` folder of a workspace does nothing - v0.5.13 (pre-release) #331

Closed timotheeguerin closed 4 months ago

timotheeguerin commented 4 months ago

Describe the bug

When working in a vitest workspace and trying to run the test on a folder above the project(e.g. packages) it does nothing with the pre-release extension (0.5.13).

I am guessing this is because vitest workspace are not aware themself of the structure above each individual project.

I am not sure if this is fixable or the tree view should show the project names as the root nodes instead of the folder structure.

Nothing major, thanks a lot for the awesome work in the 0.5.0 rewrite extension feels is feeling much nicer now.

Reproduction

  1. open the workspace example from vitest repo https://github.com/vitest-dev/vitest/tree/main/examples/workspace
  2. See this image
  3. Select packages and click run

image

  1. Result is no test are run image

Output

[INFO 2:15:03 PM] [API] Running Vitest: v1.4.0 (/Users/timotheeguerin/dev/test/vitest-repro/vitest.workspace.ts)
[INFO 2:15:04 PM] [API] Vitest process 73502 created
[INFO 2:15:06 PM] Running 1 file(s): /Users/timotheeguerin/dev/test/vitest-repro/packages/

Version

v0.5.13 (pre-release)

Validations

sheremet-va commented 4 months ago

This is fixed in the next Vitest minor (1.5.0) - should be released on Friday.

Related: https://github.com/vitest-dev/vitest/pull/5408