Created
February 16, 2024 21:21
-
-
Save ejona86/5afbe84d6c149b16dc823bf97d4964f8 to your computer and use it in GitHub Desktop.
Execute Gradle test many times
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for (int x = 0; x < 10; x++) { | |
tasks.test.dependsOn tasks.register('test' + x, Test) { | |
Task test = tasks.test | |
useJUnit() | |
include test.includes | |
exclude test.excludes | |
classpath = test.classpath | |
executable = test.executable | |
jvmArgs = test.jvmArgs | |
options.copyFrom test.options | |
} | |
} | |
# Use configuration cache to run them in parallel | |
# gradle test --configuration-cache |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment