Skip to content

Commit abe1307

Browse files
committed
Removed check for mixed JUnit 5 and 6 versions, adjusted error message in RemotePluginTestRunner
Fixes: #2045
1 parent 2b81907 commit abe1307

File tree

4 files changed

+3
-106
lines changed

4 files changed

+3
-106
lines changed

ui/org.eclipse.pde.junit.runtime/src/org/eclipse/pde/internal/junit/runtime/RemotePluginTestRunner.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ private static String getState(int state) {
134134
private static ClassLoader createJUnit5PluginClassLoader(String testPluginName) {
135135
Bundle testBundle = Platform.getBundle(testPluginName);
136136
if (testBundle == null) {
137-
throw new IllegalArgumentException("Bundle \"" + testPluginName + "\" not found. Possible causes include missing dependencies, too restrictive version ranges, or a non-matching required execution environment."); //$NON-NLS-1$ //$NON-NLS-2$
137+
throw new IllegalArgumentException("Bundle \"" + testPluginName + "\" not found. Possible causes include missing dependencies, too restrictive version ranges, mixed JUnit versions, or a non-matching required execution environment."); //$NON-NLS-1$ //$NON-NLS-2$
138138
}
139139
Bundle junit5RuntimeBundle = Platform.getBundle("org.eclipse.jdt.junit5.runtime"); //$NON-NLS-1$
140140
List<Bundle> platformEngineBundles = findTestEngineBundles();

ui/org.eclipse.pde.launching/src/org/eclipse/pde/internal/launching/JUnitLaunchValidationOperation.java

Lines changed: 0 additions & 98 deletions
This file was deleted.

ui/org.eclipse.pde.launching/src/org/eclipse/pde/internal/launching/pderesources.properties

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,8 @@ JUnitLaunchConfiguration_error_JUnitLaunchAndRuntimeMissmatch = Launch targets J
2929
Therefore this launch is expected to fail.\n\
3030
\n\
3131
Either update the launch configuration to target JUnit {1},\n\
32-
or restrict the versions of JUnit Jupiter and JUnit Platform\n\
33-
by specifying corresponding version bounds\n\
34-
in your test-project to match only JUnit {0}.
32+
or restrict the version bounds of {3}\n\
33+
in bundle {2} to match only JUnit {0}.
3534

3635
OSGiLaunchConfiguration_cannotFindLaunchConfiguration=Cannot find the {0} OSGi framework.
3736
OSGiLaunchConfiguration_selected=selected

ui/org.eclipse.pde.launching/src/org/eclipse/pde/launching/JUnitLaunchConfigurationDelegate.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,6 @@
7171
import org.eclipse.pde.internal.core.util.VersionUtil;
7272
import org.eclipse.pde.internal.launching.IPDEConstants;
7373
import org.eclipse.pde.internal.launching.JUnitLaunchRequirements;
74-
import org.eclipse.pde.internal.launching.JUnitLaunchValidationOperation;
7574
import org.eclipse.pde.internal.launching.PDELaunchingPlugin;
7675
import org.eclipse.pde.internal.launching.PDEMessages;
7776
import org.eclipse.pde.internal.launching.launcher.BundleLauncherHelper;
@@ -519,9 +518,6 @@ protected void preLaunchCheck(ILaunchConfiguration configuration, ILaunch launch
519518
fAllBundles = fModels.keySet().stream().collect(Collectors.groupingBy(m -> m.getPluginBase().getId(), LinkedHashMap::new, Collectors.toCollection(ArrayList::new)));
520519
launchMode = launch.getLaunchMode();
521520

522-
JUnitLaunchValidationOperation junitValidation = new JUnitLaunchValidationOperation(configuration, fModels.keySet());
523-
LaunchPluginValidator.runValidationOperation(junitValidation, monitor);
524-
525521
// implicitly add the plug-ins required for JUnit testing if necessary
526522
JUnitLaunchRequirements.addRequiredJunitRuntimePlugins(configuration, fAllBundles, fModels);
527523

0 commit comments

Comments
 (0)