use of org.gradle.api.internal.tasks.testing.JvmTestExecutionSpec in project gradle by gradle.
the class Test method createTestExecutionSpec.
/**
* {@inheritDoc}
*
* @since 4.4
*/
@Override
protected JvmTestExecutionSpec createTestExecutionSpec() {
validateToolchainConfiguration();
JavaForkOptions javaForkOptions = getForkOptionsFactory().newJavaForkOptions();
copyTo(javaForkOptions);
JavaModuleDetector javaModuleDetector = getJavaModuleDetector();
boolean testIsModule = javaModuleDetector.isModule(modularity.getInferModulePath().get(), getTestClassesDirs());
FileCollection classpath = javaModuleDetector.inferClasspath(testIsModule, stableClasspath);
FileCollection modulePath = javaModuleDetector.inferModulePath(testIsModule, stableClasspath);
return new JvmTestExecutionSpec(getTestFramework(), classpath, modulePath, getCandidateClassFiles(), isScanForTestClasses(), getTestClassesDirs(), getPath(), getIdentityPath(), getForkEvery(), javaForkOptions, getMaxParallelForks(), getPreviousFailedTestClasses());
}
Aggregations