Skip to content

Commit

Permalink
iterate over configurations instead of copy/paste
Browse files Browse the repository at this point in the history
  • Loading branch information
keturn committed May 9, 2020
1 parent efee219 commit ec79dec
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ dependencies {
codeMetrics group: 'org.terasology.config', name: 'codemetrics', version: '1.4.0', ext: 'zip'
}

configurations.named("testRuntimeClasspath") {
configurations.matching({ it =~ ~/test(Runtime|Compile|Implementation)Classpath/ }).all {
gradlegoo.prefers(getResolutionStrategy(), "logging", "jcl-api-capability", "jcl-over-slf4j", "jcl should prefer slf4j when available")
gradlegoo.prefers(getResolutionStrategy(), "logging", "slf4j-impl-capability", "spf4j-slf4j-test", "tests use slf4j-test")

Expand All @@ -156,13 +156,6 @@ configurations.named("testRuntimeClasspath") {
exclude group: "org.hamcrest", module: "hamcrest-library"
}

configurations.named("testCompileClasspath") {
gradlegoo.prefers(getResolutionStrategy(), "logging", "jcl-api-capability", "jcl-over-slf4j", "jcl should prefer slf4j when available")
gradlegoo.prefers(getResolutionStrategy(), "logging", "slf4j-impl-capability", "spf4j-slf4j-test", "tests use slf4j-test")

exclude group: "org.hamcrest", module: "hamcrest-core"
exclude group: "org.hamcrest", module: "hamcrest-library"
}

// Set the expected module Java level (can use a higher Java to run, but should not use features from a higher Java)
sourceCompatibility = 1.11
Expand Down

0 comments on commit ec79dec

Please sign in to comment.