microsoft / microsoft/vscode-java-test

Cannot run tests when setting "java.import.maven.disableTestClasspathFlag": "true"

Open
#1,690 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

ai-triaged bug junit maven test-discovery
Dominant language
TypeScript
Stars
340
Forks
173
Avg merge
1d 19h
Merged PRs (30d)
18

Description

Hi, when setting the property "java.import.maven.disableTestClasspathFlag": "true" in .vscode/settings.xml the test extension seems to break.
No tests are discoverable in the Test Explorer and the run icons in the gutter disappear. Tested on multiple systems and on a fresh/clean install of VsCode. This is on Window, both natively and via WSL2.

"java.import.maven.disableTestClasspathFlag": "true" (Not working)

image

"java.import.maven.disableTestClasspathFlag": "false" (Works as expected)

image

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue in a Java project with "java.import.maven.disableTestClasspathFlag" set to true in .vscode/settings.xml, comparing test discovery and gutter run icons with the setting false. Start by tracing the test extension's Maven import and test discovery behavior; done means tests are discoverable and runnable with the flag enabled on the reported Windows and WSL2 setups.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, typescript, vscode
Domain
developer-experience, testing-qa
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.