Skip to content

Commit

Permalink
fix test suites
Browse files Browse the repository at this point in the history
  • Loading branch information
adamleantech committed Mar 9, 2023
1 parent fb2d59b commit 3cc0ab8
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 44 deletions.
43 changes: 21 additions & 22 deletions instrumentation/logback/logback-mdc-1.0/javaagent/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,28 @@ testing {
}
}
}
}
}

configurations {
named("addBaggageTestImplementation") {
extendsFrom(configurations["testImplementation"])
withType(JvmTestSuite::class) {
dependencies {
if (findProperty("testLatestDeps") as Boolean) {
implementation("ch.qos.logback:logback-classic:+")
} else {
implementation("ch.qos.logback:logback-classic") {
version {
strictly("1.0.0")
}
}
implementation("org.slf4j:slf4j-api") {
version {
strictly("1.6.4")
}
}
}

implementation(project(":instrumentation:logback:logback-mdc-1.0:testing"))
implementation(project(":instrumentation:logback:logback-mdc-1.0:javaagent"))
}
}
}
}

Expand All @@ -44,23 +60,6 @@ dependencies {
strictly("1.6.4")
}
}

if (findProperty("testLatestDeps") as Boolean) {
testImplementation("ch.qos.logback:logback-classic:+")
} else {
testImplementation("ch.qos.logback:logback-classic") {
version {
strictly("1.0.0")
}
}
testImplementation("org.slf4j:slf4j-api") {
version {
strictly("1.6.4")
}
}
}

testImplementation(project(":instrumentation:logback:logback-mdc-1.0:testing"))
}

tasks {
Expand Down
44 changes: 22 additions & 22 deletions instrumentation/logback/logback-mdc-1.0/library/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,33 @@ testing {
}
}
}
}
}

configurations {
named("addBaggageTestImplementation") {
extendsFrom(configurations["testImplementation"])
withType(JvmTestSuite::class) {
dependencies {
if (findProperty("testLatestDeps") as Boolean) {
implementation("ch.qos.logback:logback-classic:+")
} else {
implementation("ch.qos.logback:logback-classic") {
version {
strictly("1.0.0")
}
}
implementation("org.slf4j:slf4j-api") {
version {
strictly("1.6.4")
}
}
}

implementation(project(":instrumentation:logback:logback-mdc-1.0:testing"))
implementation(project(":instrumentation:logback:logback-mdc-1.0:library"))
}
}
}
}

dependencies {

// pin the version strictly to avoid overriding by dependencyManagement versions
compileOnly("ch.qos.logback:logback-classic") {
version {
Expand All @@ -34,23 +51,6 @@ dependencies {
strictly("1.6.4")
}
}

if (findProperty("testLatestDeps") as Boolean) {
testImplementation("ch.qos.logback:logback-classic:+")
} else {
testImplementation("ch.qos.logback:logback-classic") {
version {
strictly("1.0.0")
}
}
testImplementation("org.slf4j:slf4j-api") {
version {
strictly("1.6.4")
}
}
}

testImplementation(project(":instrumentation:logback:logback-mdc-1.0:testing"))
}

tasks {
Expand Down

0 comments on commit 3cc0ab8

Please sign in to comment.