2020-06-15 10:59:55 +00:00
|
|
|
plugins {
|
|
|
|
id 'java'
|
|
|
|
}
|
|
|
|
|
|
|
|
repositories {
|
|
|
|
mavenCentral()
|
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
|
|
|
testImplementation('junit:junit:4.12')
|
|
|
|
}
|
2021-08-27 11:40:14 +00:00
|
|
|
|
|
|
|
tasks.named("test").configure {
|
2021-08-27 12:36:29 +00:00
|
|
|
// Use an environment variable to bypass config-cache checks
|
|
|
|
if (System.getenv('VERIFY_CACHED_CONFIGURATION') != null) {
|
|
|
|
throw new RuntimeException("Configuration was not cached: unexpected configuration of test task")
|
|
|
|
}
|
2021-08-27 11:40:14 +00:00
|
|
|
doLast {
|
|
|
|
if (System.properties.verifyCachedBuild) {
|
|
|
|
throw new RuntimeException("Build was not cached: unexpected execution of test task")
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|