Skip to content

fix(vscode): run the file, not a test name, from the Run Test commands - #465

Merged
pbertsch merged 1 commit into
mainfrom
fix/vscode-run-test-name
Oct 15, 2026
Merged

pbertsch merged 1 commit into
mainfrom
fix/vscode-run-test-name

Conversation

@pbertsch

Copy link
Copy Markdown
Member

Summary

  • The VS Code extension passed --name <test> to probe test in four places: the Run Test at Cursor command, the CodeLens buttons (run, per-session run and debug), and the Tests view. This version of the CLI defines no such flag, so each of those runs failed with an unknown-flag error.
  • The fix removes the flag, so those commands run the file that holds the test. "FlutterProbe: Run Test File at Cursor" keeps its command id, so the Ctrl+Shift+T binding still works. The CodeLens titles and tooltips, and the docs, say that a run covers the file. The CLI is not changed, and no flag is added.
  • A node test reads the extension's sources and fails if any of them passes --name again. It skips itself, because it names the flag.
  • A changelog entry goes under Unreleased → Fixed.

Test plan

  • npm test in vscode/: compile, then 25 node:test tests, including the new guard
  • Not run inside VS Code: the commands and the CodeLens buttons were compiled, not run
  • Not run against a device

🤖 Generated with Claude Code

probe test defines no per-test filter in this version, so every run that passed --name failed with an unknown-flag error. The Run Test commands, the CodeLens buttons and the Tests view now run the file that holds the test, and their titles and docs say so. A node test keeps --name out of the extension sources.
@pbertsch
pbertsch requested a review from a team as a code owner October 15, 2026 05:49
@pbertsch
pbertsch merged commit 5617ca8 into main Oct 15, 2026
21 of 24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant