Skip to content

Commit

Permalink
Invoke jmhJar as a part of build procedure to ensure that benchmark…
Browse files Browse the repository at this point in the history
…s always compile (Kotlin#3019)

* Invoke jmhJar as a part of the build procedure to ensure that benchmarks always compile
  • Loading branch information
ndkoval committed Nov 11, 2021
1 parent 22e31b7 commit 30b057e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
8 changes: 7 additions & 1 deletion benchmarks/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,19 @@ extensions.configure<JMHPluginExtension>("jmh") {
// includeTests = false
}

tasks.named<Jar>("jmhJar") {
val jmhJarTask = tasks.named<Jar>("jmhJar") {
archiveBaseName by "benchmarks"
archiveClassifier by null
archiveVersion by null
destinationDirectory.file("$rootDir")
}

tasks {
build {
dependsOn(jmhJarTask)
}
}

dependencies {
implementation("org.openjdk.jmh:jmh-core:1.26")
implementation("io.projectreactor:reactor-core:${version("reactor")}")
Expand Down
2 changes: 1 addition & 1 deletion settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ pluginManagement {

// JMH
id "net.ltgt.apt" version "0.21"
id "me.champeau.gradle.jmh" version "0.5.2"
id "me.champeau.gradle.jmh" version "0.5.3"
}

repositories {
Expand Down

0 comments on commit 30b057e

Please sign in to comment.