Run and debug JUnit and TestNG tests in VS Code
open sourceMITfree
Test Runner for Java is Microsoft's extension (vscjava.vscode-java-test) that runs and debugs Java tests in Visual Studio Code: JUnit 4, 5 and 6 and TestNG, though not JUnit 3-style tests. It puts run buttons beside test classes and methods, lists tests in VS Code's Test Explorer, shows a test report and lets you customize test configurations. It works with Red Hat's Language Support for Java and Microsoft's Debugger for Java, needs JDK 17 or later, and is on the VS Code Marketplace and Open VSX.
Problems it solves
- run a single JUnit test from VS Code
- see my Java test results in the editor
- debug a failing TestNG test in VS Code
Features
- run and debug tests from the editor
- JUnit 4, 5 and 6 and TestNG
- Test Explorer integration
- test reports
- custom test configurations
Limitations
Alternatives
The same job
These do what Test Runner for Java does.
- Jest Runner Runs and debugs a single JavaScript or TypeScript test from VS Code, for Jest, Vitest, Playwright and more
