Created
June 13, 2011 00:24
-
-
Save breskeby/1022162 to your computer and use it in GitHub Desktop.
Incremental test task execution on jenkins
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
apply plugin:'groovy' | |
repositories{ | |
mavenCentral() | |
} | |
dependencies{ | |
groovy "org.codehaus.groovy:groovy-all:1.7.10" | |
testCompile "junit:junit:4.8.2" | |
} | |
task jenkinsTest{ | |
inputs.files test.outputs.files | |
doLast{ | |
def timestamp = System.currentTimeMillis() | |
test.testResultsDir.eachFile { it.lastModified = timestamp } | |
} | |
} | |
build.dependsOn(jenkinsTest) | |
task wrapper(type:Wrapper){ | |
gradleVersion = '1.0-milestone-3' | |
} |
Hello,
Where am I going to configure that build.gradle file?
Raymund
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi,
Thanks for sharing this! 👍 The testResultsDir is a deprecated property which is removed in Gradle 2. I have modified this code to be compatible with Gradle 2, and I also created it as a plugin.
Mats