Last active
January 21, 2019 11:28
-
-
Save durimkryeziu/e987631e1ed304582fbfa75d970d0ee6 to your computer and use it in GitHub Desktop.
Gradle Configuration for Integration Tests
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
// Tested with Gradle 5.0 | |
sourceSets { | |
integrationTest { | |
compileClasspath += sourceSets.main.output | |
runtimeClasspath += sourceSets.main.output | |
resources.srcDir file('src/integrationtest/resources') | |
} | |
} | |
configurations { | |
integrationTestImplementation.extendsFrom testImplementation | |
integrationTestRuntimeOnly.extendsFrom testRuntimeOnly | |
} | |
task integrationTest(type: Test) { | |
description = 'Runs the integration tests.' | |
group = 'verification' | |
testClassesDirs = sourceSets.integrationTest.output.classesDirs | |
classpath = sourceSets.integrationTest.runtimeClasspath | |
outputs.upToDateWhen { false } | |
shouldRunAfter test | |
} | |
check.dependsOn -= integrationTest |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment