Configure kotlin directly in only project that uses it and enable testLatestDeps (#3081)
This commit is contained in:
parent
d755654c29
commit
5f373b3062
|
@ -19,8 +19,6 @@ ext {
|
||||||
logback : "1.2.3",
|
logback : "1.2.3",
|
||||||
bytebuddy : "1.10.18", // Also explicitly specified in buildSrc
|
bytebuddy : "1.10.18", // Also explicitly specified in buildSrc
|
||||||
scala : "2.11.12",
|
scala : "2.11.12",
|
||||||
kotlin : "1.4.0",
|
|
||||||
coroutines : "1.3.0",
|
|
||||||
springboot : "2.3.1.RELEASE",
|
springboot : "2.3.1.RELEASE",
|
||||||
junit5 : "5.7.1",
|
junit5 : "5.7.1",
|
||||||
checkerFramework : "3.6.1",
|
checkerFramework : "3.6.1",
|
||||||
|
@ -100,8 +98,6 @@ ext {
|
||||||
"org.slf4j:jul-to-slf4j:${versions.slf4j}",
|
"org.slf4j:jul-to-slf4j:${versions.slf4j}",
|
||||||
],
|
],
|
||||||
scala : "org.scala-lang:scala-library:${versions.scala}",
|
scala : "org.scala-lang:scala-library:${versions.scala}",
|
||||||
kotlin : "org.jetbrains.kotlin:kotlin-stdlib:${versions.kotlin}",
|
|
||||||
coroutines : "org.jetbrains.kotlinx:kotlinx-coroutines-core:${versions.coroutines}",
|
|
||||||
junitApi : "org.junit.jupiter:junit-jupiter-api:${versions.junit5}",
|
junitApi : "org.junit.jupiter:junit-jupiter-api:${versions.junit5}",
|
||||||
assertj : "org.assertj:assertj-core:${versions.assertj}",
|
assertj : "org.assertj:assertj-core:${versions.assertj}",
|
||||||
awaitility : "org.awaitility:awaitility:${versions.awaitility}",
|
awaitility : "org.awaitility:awaitility:${versions.awaitility}",
|
||||||
|
|
|
@ -1,8 +0,0 @@
|
||||||
// Enable testing kotlin code in groovy spock tests.
|
|
||||||
apply plugin: 'org.jetbrains.kotlin.jvm'
|
|
||||||
|
|
||||||
tasks.named('compileTestGroovy').configure {
|
|
||||||
//Note: look like it should be `classpath += files(sourceSets.test.kotlin.classesDirectory)`
|
|
||||||
//instead, but kotlin plugin doesn't support it (yet?)
|
|
||||||
classpath += files(compileTestKotlin.destinationDir)
|
|
||||||
}
|
|
|
@ -8,7 +8,6 @@ buildscript {
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
classpath "net.bytebuddy:byte-buddy-gradle-plugin:${versions.bytebuddy}"
|
classpath "net.bytebuddy:byte-buddy-gradle-plugin:${versions.bytebuddy}"
|
||||||
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:${versions.kotlin}"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
plugins {
|
plugins {
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
|
plugins {
|
||||||
|
id 'org.jetbrains.kotlin.jvm'
|
||||||
|
}
|
||||||
|
|
||||||
apply from: "$rootDir/gradle/instrumentation.gradle"
|
apply from: "$rootDir/gradle/instrumentation.gradle"
|
||||||
apply from: "$rootDir/gradle/test-with-kotlin.gradle"
|
|
||||||
|
|
||||||
muzzle {
|
muzzle {
|
||||||
pass {
|
pass {
|
||||||
|
@ -18,6 +21,13 @@ dependencies {
|
||||||
compileOnly deps.opentelemetryKotlin
|
compileOnly deps.opentelemetryKotlin
|
||||||
|
|
||||||
testImplementation deps.opentelemetryKotlin
|
testImplementation deps.opentelemetryKotlin
|
||||||
testImplementation deps.kotlin
|
testImplementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8"
|
||||||
testImplementation deps.coroutines
|
// Use first version with flow support since we have tests for it.
|
||||||
|
testLibrary "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.3.0"
|
||||||
|
}
|
||||||
|
|
||||||
|
tasks.named('compileTestGroovy').configure {
|
||||||
|
//Note: look like it should be `classpath += files(sourceSets.test.kotlin.classesDirectory)`
|
||||||
|
//instead, but kotlin plugin doesn't support it (yet?)
|
||||||
|
classpath += files(compileTestKotlin.destinationDir)
|
||||||
}
|
}
|
|
@ -7,6 +7,7 @@ pluginManagement {
|
||||||
id "io.github.gradle-nexus.publish-plugin" version "1.0.0"
|
id "io.github.gradle-nexus.publish-plugin" version "1.0.0"
|
||||||
id "me.champeau.jmh" version "0.6.4"
|
id "me.champeau.jmh" version "0.6.4"
|
||||||
id "net.ltgt.errorprone" version "1.3.0"
|
id "net.ltgt.errorprone" version "1.3.0"
|
||||||
|
id 'org.jetbrains.kotlin.jvm' version '1.5.10'
|
||||||
id 'org.unbroken-dome.test-sets' version '4.0.0'
|
id 'org.unbroken-dome.test-sets' version '4.0.0'
|
||||||
id "nebula.release" version "15.3.0"
|
id "nebula.release" version "15.3.0"
|
||||||
id 'org.gradle.test-retry' version '1.2.0'
|
id 'org.gradle.test-retry' version '1.2.0'
|
||||||
|
|
Loading…
Reference in New Issue