All notable changes to the "vscode-java-test" extension will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
- Support enabling tests for unmanaged folder project when there is no test framework found on the project's classpath. You can find the feature in the
Testing
explorer. #1344
- The
@Test
method will be selected by default when usingGenerating Tests...
source action. #1350
- Reduce the line spacing in test messages PR#1345
-
Add more options in the setting
java.test.config
:More details, please see our document.
-
Support jumping between tests and corresponding test subjects #660
- Show the test messages at where they happen #1266
- Improve the experience of displaying the JUnit 4's parameterized tests #1296
- Changed the extension name to
Test Runner for Java
. PR#1272
- Adopted new VS Code testing API. For more details, please refer to the README page.
- Support new Source Action:
Generate Tests...
in source files to help scaffold the tests. #1172
- Support new Source Action:
Generate Tests...
in the test source files. #1172
- Add welcome view in Test explorer when there is no folders opened. PR#1141
- Apply the new extension icon. PR#1144
- Support running tests from the Java Project explorer for Maven and Gradle projects. PR#1125
- Improve the accessibility of the test status bar item. #1126
- improve the accessibility of the test report page. #1128
- Opening files from the
Test
explorer now has the same experience as theFile
explorer. PR#1129
- Change the scope of the setting
java.test.report.showAfterExecution
towindow
. #1104 - Adopt the progress reporter API proposed in
Debugger for Java@0.30.0
. PR#1119To prevent the notification dialog showing up, you can set the setting
java.silentNotification
totrue
.
- Automatically switch to
DEBUG CONSOLE
when a new test session starts. #1106 - Do not show the
Test Explorer
for a non-Java workspace. #793
- Navigate from stacktrace line to proper file in test reports. #384
- Only show the
Migrate Deprecated 'launch.test.json'
command when workspace has the deprecated files. PR#1084 - Update the run buttons in the Test Explorer. PR#1086
- Add new commands
java.test.editor.run
andjava.test.editor.debug
to run and debug tests in current file. PR#1066
- The field
vmargs
injava.test.config
is deprecated,vmArgs
is used to align with the debug launch configuration. #852
- The adaptive debounce mechanism when resolving Code Lenses is removed since it is embedded in Visual Studio Code 1.50.0. PR#1074
- Adopt the adaptive debounce mechanism when resolving Code Lenses. PR#1051
- Use ASTProvider when parse the AST nodes. PR#1052
- Improve the performance for resolving test Code Lenses. #1039
- Adopt welcome view for Test explorer in LightWeight Mode. PR#1046
- Add relaunch tests command. #1030
- Add the panel icon for the test report. #PR1032
- Show test report via keyboard shortcut and command palette. #1002
- Adopt the new APIs for the LightWeight mode. PR#1019
- Run directly if the test is triggered from a method node in explorer. PR#1033
- Support JUnit 5's @Testable in Code Lenses. PR#980
- Resolve the Code Lenses only when the current source file is on test source paths. PR#997
- Add
sourcePaths
key injava.test.config
to specify source paths. #982
- Skipped tests can be toggled out in the test report. #754
- Migrate the icons in test explorer to VS Code Icons. PR#961
- Show running status in the Test Explorer during the execution. #790
- Show test status on test method nodes in Test Explorer. #890
- Use Octicon to replace the Emoji for Code Lens. #845
- The setting
java.test.forceBuildBeforeLaunchTest
is removed, please usejava.debug.settings.forceBuildBeforeLaunch
instead. PR#850 - The setting
java.test.saveAllBeforeLaunchTest
is removed, now the unsaved files will always be saved before launching the tests.PR#861
- Add
java.test.saveAllBeforeLaunchTest
setting to specify whether to automatically save the files before launching the tests. #468 - Add
java.test.forceBuildBeforeLaunchTest
setting to specify whether to automatically build the workspace before launching the tests. #781
- The runner for JUnit 4 is changed to Eclipse JUnit 4 Runner. PR#795
- The title of the Test Explorer is changed to
Java
. PR#796
- Add
redhat.java
into the extension dependency list. PR#760
- Support customizing the visibility of
Run Test
andDebug Test
CodeLens through setting:java.test.editor.enableShortcuts
. #374
- Support automatically show the test report after execution. #673
- Support JUnit 5
@Nested
annotation. #685
- Support Junit 5 TestFactory annotation. #644
- Automatically add "--enable-preview" to vmargs when necessary. #669
- Add a new command
Java: Migrate Deprecated 'launch.test.json'
to help migrate thelaunch.test.json
files. PR#664
- Stop supporting
launch.test.json
. #650
- Support JUnit 4
@RunWith
annotation. #272 - Support JUnit 4
@Theory
annotation. #628 - Support JUnit 5
@RepeatedTest
annotation. #594
- Support ${workspaceFolder} in 'vmargs', 'args' and the value of each entry in 'env' in the test configurations. #602
- SecurityException when running JUnit 5 tests. #477
- Wrong order of arguments passing to Test Runner. #592
- Fail to resolve configurations which contain ${workspaceFolder}. #599
- Report page always goes back to the top after the navigation button is clicked. #606
- Redesign the user experience of running tests with configurations. More details #524
- Fix the bug that test scope is wrong when triggering tests from inner class level. #411
- Fix the bug that tests which contain inner class will be skipped if triggered from the test explorer. #460
- Improve the test output format. #505
- Pack the test report resources into the extension vsix. 550
- Add Chinese language support. #437
- Use webpack to improve the extension startup time. #495
- Change the activation events of the extension. #516
- Change the style of the test report. #517
- Fix the bug that test explorer will keep refreshing when opening a large project. #461
- Fix several bugs that cause the extension fails to run test cases. (#134, #488, #504, #515)
- Add a way to persist test logs into log files. #452
- Add @DisplayName support in the test report for JUnit 5. #446
- Add @ParameterizedTest support for JUnit 5. #107
- Improve the test report page. (#397, #486, #489)
- Change the foreground color of the status bar items. #467
- Fix the bug that test runners will run forever. #482
- Add JUnit 5's @DisplayName support in test explorer. (Thanks for @BaerMitUmlaut)
- "Cannot read property 'indexOf' of undefined" bug when running JUnit 5 tests. #455
- Will run all tests in class if triggering test from method level in test explorer. #441
- Cannot run tests when the project is a multi-module Maven project. #443
- Add TestNG support.
- Test explorer change to lazy-load mechanism.
- Always resolve the classpath before running test jobs - no need to trigger
Refresh Classpath
anymore.
- Sort packages alphabetically in Test Explorer. #310
- Get JAVA_HOME location through calling the API exposed by the Java Language Server. #319
- Fix a bug that code lenses are not in the correct place. #36
- Test explorer will always show in the Activity Bar after the extension is activated. #271
- Fix a bug that Test Runner for Java will interfere with Java language server. #260
- Fix 'command not found error' when triggering commands. #289
- Refine the logic to consume test output for JUnit test runner.
- Add project info into
TestSuite
, and run the tests per project to avoid the conflict of classpaths between projects. - Fix the issue that test output would be truncated when it exceeds buffer size.
- Fix the issue that the test runner hangs for some tests.
- Fix classpath resolution issue for the scenario that there are multiple projects in a workspace folder. #176
- Fix bug for default working directory. #229
- Fix bug for test output analyzer. #231
- Add environment variable into test configuration schema.(Thanks @thwfreak for contributing the pull request)
- Fix bug for environment variables in the test configuration. #222
- Support configuring environment variables in test configuration.
- Move test explorer to Test View container(Thanks @sandy081 for contributing to the pull request.)
- Auto refresh test report when files update. And still show previous test report until user reruns the test.
- Support cancelling a test run. Partial test result would be updated.
- Add JSON schema validation for test configuration file.
- Add
default
field in test configuration where user could specify the default config to pick while invoking commandRun Test
.
- Behavior change: after a test run, always show the test report and update test status(might be partial) even when test runner failed.
- Removed
Run With Config
andDebug with Config
codelens for simplicity. Still, you can invoke the command from test explorer. - Renamed the test configuration file from
test-launch.json
tolaunch.test.json
. Original test configuration file won't be removed, but you might need to copy its content to the new one if you have customized config.
-
Support test configuration. You can now configure your test setting through command
java.test.configure
. It supports following configuration:- projectName
- workingDirectory
- args
- vmargs
- preLaunchTask
And you can run/debug with config through codelens or test explorer context menu.
- Support basic feature of JUnit5
- Trigger tests from test explorer. We now support folder/package/class/method levels or you can run all.
- Add command
Java:Open Log
to open log file. - Add setting
java.test.report.position
to specify the position of test report.
- Fix bug #83
- Fix bug #86
- Fix bug #90
- Fix bug that test explorer would disappear when opening test report.
- Add Test explorer, you can view/locate all tests from the explorer.
- Add status bar item to show test status and statistics.
- Add command to show test output window. By default it wouldn't be open while running tests.
- Make test report more user friendly. No need to save test report any more
- Fix bug #34
- Support JUnit (v4.8.0+) test cases
- Run test cases
- Debug test cases
- View test logs