Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Java 21 on CI and minor updates #264

Merged
merged 22 commits into from
Feb 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
be75b34
Update dependency jacoco to v0.8.11
renovate[bot] Jan 18, 2024
c23a91c
Update actions/setup-java action to v4
renovate[bot] Jan 18, 2024
6b8bb77
Update dependency com.gradle.publish:plugin-publish-plugin to v1.2.1
renovate[bot] Jan 18, 2024
f5c461e
Update plugin org.gradle.toolchains.foojay-resolver-convention to v0.8.0
renovate[bot] Jan 18, 2024
2142f49
Update actions/checkout action to v4
renovate[bot] Jan 18, 2024
d608986
Update plugin com.gradle.enterprise to v3.16.1
renovate[bot] Jan 18, 2024
97a8db4
Update dependency org.apache.commons:commons-lang3 to v3.14.0
renovate[bot] Jan 18, 2024
a719192
Update plugin org.nosphere.apache.rat to v0.8.1
renovate[bot] Jan 18, 2024
467fcb9
Update plugin me.champeau.jmh to v0.7.2
renovate[bot] Jan 18, 2024
71da7c0
Update dependency org.scala-lang:scala-library to v2.13.12
renovate[bot] Jan 18, 2024
b800c4c
Update dependency org.junit.jupiter:junit-jupiter-api to v5.10.1
renovate[bot] Jan 18, 2024
db64901
Update dependency org.jetbrains.kotlin:kotlin-gradle-plugin to v1.9.22
renovate[bot] Jan 18, 2024
42340ee
Update dependency org.codehaus.groovy:groovy-all to v3.0.20
renovate[bot] Jan 18, 2024
b4284aa
Use Java 21 on CI
Goooler Jan 18, 2024
8252f32
Reuse GradleRunner config
Goooler Jan 18, 2024
f32d5fe
Update plugin com.gradle.enterprise to v3.16.2
renovate[bot] Jan 26, 2024
10f6990
Update gradle/gradle-build-action action to v3
renovate[bot] Jan 27, 2024
9918be5
Update gradle/wrapper-validation-action action to v2
renovate[bot] Jan 29, 2024
2c21a68
Update dependency gradle to v8.6
renovate[bot] Feb 2, 2024
4cd1383
Update dependency org.junit.jupiter:junit-jupiter-api to v5.10.2
renovate[bot] Feb 4, 2024
034dbcc
Update dependency org.scala-lang:scala-library to v2.13.13
renovate[bot] Feb 21, 2024
11c58f6
Update dependency io.github.goooler.shadow:shadow-gradle-plugin to v8…
renovate[bot] Feb 19, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ jobs:
os: [ ubuntu-latest, windows-latest ]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: 17
- uses: gradle/wrapper-validation-action@v1
java-version: 21
- uses: gradle/wrapper-validation-action@v2
- name: Setup Gradle
uses: gradle/gradle-build-action@v2
uses: gradle/actions/setup-gradle@v3

- name: Execute Gradle build
run: ./gradlew build
2 changes: 1 addition & 1 deletion build-logic/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,5 @@ repositories {
}

dependencies {
implementation("com.gradle.publish:plugin-publish-plugin:1.2.0")
implementation("com.gradle.publish:plugin-publish-plugin:1.2.1")
}
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
plugins {
jacoco
id("me.champeau.buildscan-recipes") version "0.2.3"
id("org.nosphere.apache.rat") version "0.8.0"
id("org.nosphere.apache.rat") version "0.8.1"
id("net.nemerosa.versioning") version "3.0.0"
id("com.github.kt3k.coveralls") version "2.12.2"
id("me.champeau.convention-test")
Expand Down
4 changes: 2 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ project_website=https://github.com/melix/jmh-gradle-plugin
project_issues=https://github.com/melix/jmh-gradle-plugin/issues
project_vcs=https://github.com/melix/jmh-gradle-plugin.git

jacocoVersion = 0.8.10
jacocoVersion = 0.8.11
jmhVersion = 1.37
shadowVersion = 7.1.2
shadowForkVersion = 8.1.3
shadowForkVersion = 8.1.5
spockVersion = 2.3-groovy-3.0

org.gradle.jvmargs=-Xmx4g -Dfile.encoding=UTF-8
Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.6-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down
4 changes: 2 additions & 2 deletions samples/simple-java/groovy-dsl/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@
*/
plugins {
id 'java-library'
id "me.champeau.jmh" version "0.7.1"
id "me.champeau.jmh" version "0.7.2"
}

repositories {
mavenCentral()
}

dependencies {
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.10.0'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.10.2'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine'
}

Expand Down
4 changes: 2 additions & 2 deletions samples/simple-java/kotlin-dsl/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@
*/
plugins {
`java-library`
id("me.champeau.jmh") version "0.7.1"
id("me.champeau.jmh") version "0.7.2"
}

repositories {
mavenCentral()
}

dependencies {
testImplementation("org.junit.jupiter:junit-jupiter-api:5.10.0")
testImplementation("org.junit.jupiter:junit-jupiter-api:5.10.2")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine")
}

Expand Down
4 changes: 2 additions & 2 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ pluginManagement {
}

plugins {
id("com.gradle.enterprise") version "3.14.1"
id("org.gradle.toolchains.foojay-resolver-convention") version "0.6.0"
id("com.gradle.enterprise") version "3.16.2"
id("org.gradle.toolchains.foojay-resolver-convention") version "0.8.0"
}

gradleEnterprise {
Expand Down
17 changes: 12 additions & 5 deletions src/funcTest/groovy/me/champeau/jmh/AbstractFuncSpec.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ abstract class AbstractFuncSpec extends Specification {
testedGradleVersion = gradleVersion
}

// TODO: We can remove this and fully enable CC in tests once bump the Shadow version to 8.1.1+.
// TODO: But Kotlin test still fails, it was suppressed in 1bab41646df6f47aea84ea3febeeec1c76cd2e79, need to investigate.
protected void withoutConfigurationCache(String reason) {
noConfigurationCacheReason = reason
}
Expand Down Expand Up @@ -83,6 +85,7 @@ abstract class AbstractFuncSpec extends Specification {
.withPluginClasspath()
.withProjectDir(projectDir)
.withArguments(arguments)
.withTestKitDir(testKitDir)
}

protected BuildResult build(String... arguments) {
Expand All @@ -94,13 +97,17 @@ abstract class AbstractFuncSpec extends Specification {
}

private List<String> calculateArguments(String... arguments) {
def gradleVersionWithConfigurationCache = testedGradleVersion >= GradleVersion.version('6.6')
if (gradleVersionWithConfigurationCache && noConfigurationCacheReason) {
println("Configuration cache disabled: $noConfigurationCacheReason")
}
(gradleVersionWithConfigurationCache && !noConfigurationCacheReason
(!noConfigurationCacheReason
? ['--stacktrace',
'--configuration-cache']
: ['--stacktrace']) + (arguments as List)
}

private static File getTestKitDir() {
def gradleUserHome = System.getenv("GRADLE_USER_HOME")
if (!gradleUserHome) {
gradleUserHome = new File(System.getProperty("user.home"), ".gradle").absolutePath
}
return new File(gradleUserHome, "testkit")
}
}
4 changes: 2 additions & 2 deletions src/funcTest/groovy/me/champeau/jmh/ParameterSpec.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,15 @@ class ParameterSpec extends AbstractFuncSpec {
usingSample("java-project")

when:
def result = build("jmhJar", "--configuration-cache")
def result = build("jmhJar")

then:
result.task(":jmhJar").outcome == SUCCESS
result.output.contains("Calculating task graph as no configuration cache is available for tasks: jmhJar") ||
result.output.contains("Calculating task graph as no cached configuration is available for tasks: jmhJar")

when:
result = build("jmhJar", "--configuration-cache")
result = build("jmhJar")

then:
result.task(":jmhJar").outcome == UP_TO_DATE
Expand Down
2 changes: 1 addition & 1 deletion src/funcTest/resources/groovy-project/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ repositories {
}

dependencies {
implementation 'org.codehaus.groovy:groovy-all:3.0.18'
implementation 'org.codehaus.groovy:groovy-all:3.0.20'
}

jmh {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ repositories {

dependencies {
testImplementation 'junit:junit:4.13.2'
testImplementation 'org.apache.commons:commons-lang3:3.13.0'
testImplementation 'org.apache.commons:commons-lang3:3.14.0'
}

jmh {
Expand Down
2 changes: 1 addition & 1 deletion src/funcTest/resources/kotlin-project/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ buildscript {
mavenCentral()
}
dependencies {
classpath 'org.jetbrains.kotlin:kotlin-gradle-plugin:1.9.0'
classpath 'org.jetbrains.kotlin:kotlin-gradle-plugin:1.9.22'
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/funcTest/resources/mixed-language-project/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ repositories {
}

dependencies {
implementation 'org.codehaus.groovy:groovy-all:3.0.18'
implementation 'org.codehaus.groovy:groovy-all:3.0.20'
}

jmh {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ repositories {
}

dependencies {
implementation 'org.scala-lang:scala-library:2.13.11'
implementation 'org.scala-lang:scala-library:2.13.13'
}

jmh {
Expand Down
2 changes: 1 addition & 1 deletion src/funcTest/resources/scala-project/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ repositories {
}

dependencies {
implementation 'org.scala-lang:scala-library:2.13.11'
implementation 'org.scala-lang:scala-library:2.13.13'
}

jmh {
Expand Down
2 changes: 1 addition & 1 deletion src/funcTest/resources/scala-shadow-project/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ repositories {
}

dependencies {
implementation 'org.scala-lang:scala-library:2.13.11'
implementation 'org.scala-lang:scala-library:2.13.13'
}

jmh {
Expand Down