Run As JUnit Test within Gradle project runs `JUnit4TestFinder` five extra times
Expected Behavior
Launching JUnit for a source folder, package, type or method should execute the JUnit4TestFinder only once.
Current Behavior
Launching JUnit for a source folder executes the JUnit4TestFinder six times. Once to find tests, 2x to get bootpath and 3x to get classpath/modulepath. Performance can be extremely slow. Original discussion: https://bugs.eclipse.org/bugs/show_bug.cgi?id=540712
Context
JUnit launch for non-Gradle project or Gradle STS project starts quickly. JUnit launch for Buildship Gradle project is slow if Java Type Hierarchy or Region-based Java Search (for tests) is slow to compute. The example project (RxJava 2.2.3) contains approx. 9000 types in the type hierarchy, of which over 7000 are anonymous inner classes within the tests.
Steps to Reproduce
You can import RxJava if you'd like. Otherwise, a typical Java project with main and test source folders with JUnit4-style test(s) should be sufficient. After compilation, Run As > JUnit Test on the test folder should execute org.eclipse.jdt.internal.junit.launcher.JUnit4TestFinder#findTestsInContainer six times for the package fragment root (srr/test/java presumably).
Your Environment
This has been confirmed with Eclipse 4.25 and Buildship 3.1.6. The RxJava I tested was 2.2.3 since that is the release at the time of the bugzilla ticket. It uses Gradle 4.3.1 and I have also bumped it to Gradle 5.1.1 so I could confirm my findings on Eclipse 4.25 which requires Java 11.
Here is a stack trace for one of the secondary operations:

@akarnokd @mauromol
Yeah, Eric, are you saying you've found the actual culprit of the incredible slowdown we have been experiencing in running JUnit tests in Eclipse for some years? :-) It would be great!