From b4ba1bfebfca160f44cbe6ed47f172bd754517c6 Mon Sep 17 00:00:00 2001 From: Kim Gi Uk <2897robo@gmail.com> Date: Mon, 19 May 2025 19:44:54 +0900 Subject: [PATCH 001/109] Add example for using `@Execution` annotation to User Guide (#4525) Resolves #2669. --------- Co-authored-by: Marc Philipp --- .../asciidoc/user-guide/writing-tests.adoc | 11 +++++++ .../example/ExplicitExecutionModeDemo.java | 30 +++++++++++++++++++ 2 files changed, 41 insertions(+) create mode 100644 documentation/src/test/java/example/ExplicitExecutionModeDemo.java diff --git a/documentation/src/docs/asciidoc/user-guide/writing-tests.adoc b/documentation/src/docs/asciidoc/user-guide/writing-tests.adoc index 4f6540554149..0c4f39c92816 100644 --- a/documentation/src/docs/asciidoc/user-guide/writing-tests.adoc +++ b/documentation/src/docs/asciidoc/user-guide/writing-tests.adoc @@ -3195,6 +3195,17 @@ execution order. Thus, in both cases, test methods in such test classes are only concurrently if the `@Execution(CONCURRENT)` annotation is present on the test class or method. +You can use the `@Execution` annotation to explicitly configure the execution mode for a +test class or method: + +[source,java] +---- +include::{testDir}/example/ExplicitExecutionModeDemo.java[] +---- + +This allows test classes or methods to opt in or out of concurrent execution regardless of +the globally configured default. + When parallel execution is enabled and a default `{ClassOrderer}` is registered (see <> for details), top-level test classes will initially be sorted accordingly and scheduled in that order. However, they are not diff --git a/documentation/src/test/java/example/ExplicitExecutionModeDemo.java b/documentation/src/test/java/example/ExplicitExecutionModeDemo.java new file mode 100644 index 000000000000..83735b7b8419 --- /dev/null +++ b/documentation/src/test/java/example/ExplicitExecutionModeDemo.java @@ -0,0 +1,30 @@ +/* + * Copyright 2015-2025 the original author or authors. + * + * All rights reserved. This program and the accompanying materials are + * made available under the terms of the Eclipse Public License v2.0 which + * accompanies this distribution and is available at + * + * https://www.eclipse.org/legal/epl-v20.html + */ + +package example; + +import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.parallel.Execution; +import org.junit.jupiter.api.parallel.ExecutionMode; + +@Execution(ExecutionMode.CONCURRENT) +class ExplicitExecutionModeDemo { + + @Test + void testA() { + // concurrent + } + + @Test + @Execution(ExecutionMode.SAME_THREAD) + void testB() { + // overrides to same_thread + } +} From dd6446433568901a9231fa6f07d0cae34d525624 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Thu, 22 May 2025 17:29:39 +0200 Subject: [PATCH 002/109] Fix `SimpleArgumentsAggregator` for fields --- .../jupiter/params/aggregator/SimpleArgumentsAggregator.java | 2 +- .../jupiter/params/ParameterizedClassIntegrationTests.java | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/junit-jupiter-params/src/main/java/org/junit/jupiter/params/aggregator/SimpleArgumentsAggregator.java b/junit-jupiter-params/src/main/java/org/junit/jupiter/params/aggregator/SimpleArgumentsAggregator.java index 25373b624f75..7537e5a64e46 100644 --- a/junit-jupiter-params/src/main/java/org/junit/jupiter/params/aggregator/SimpleArgumentsAggregator.java +++ b/junit-jupiter-params/src/main/java/org/junit/jupiter/params/aggregator/SimpleArgumentsAggregator.java @@ -40,7 +40,7 @@ public Object aggregateArguments(ArgumentsAccessor accessor, ParameterContext co @Override public Object aggregateArguments(ArgumentsAccessor accessor, FieldContext context) throws ArgumentsAggregationException { - return aggregateArguments(accessor, null, context, context.getParameterIndex()); + return aggregateArguments(accessor, context.getField().getType(), context, context.getParameterIndex()); } protected abstract Object aggregateArguments(ArgumentsAccessor accessor, Class targetType, diff --git a/jupiter-tests/src/test/java/org/junit/jupiter/params/ParameterizedClassIntegrationTests.java b/jupiter-tests/src/test/java/org/junit/jupiter/params/ParameterizedClassIntegrationTests.java index 6e678900084e..7d7946553b5e 100644 --- a/jupiter-tests/src/test/java/org/junit/jupiter/params/ParameterizedClassIntegrationTests.java +++ b/jupiter-tests/src/test/java/org/junit/jupiter/params/ParameterizedClassIntegrationTests.java @@ -1055,6 +1055,7 @@ private static class TimesTwoAggregator extends SimpleArgumentsAggregator { protected Object aggregateArguments(ArgumentsAccessor accessor, Class targetType, AnnotatedElementContext context, int parameterIndex) throws ArgumentsAggregationException { + assertThat(targetType).isEqualTo(int.class); return accessor.getInteger(0) * 2; } } From d6c42ce9798145521c772b0fb78657ebbf44665b Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Mon, 26 May 2025 12:57:56 +0200 Subject: [PATCH 003/109] Add missing word --- documentation/src/docs/asciidoc/user-guide/writing-tests.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/documentation/src/docs/asciidoc/user-guide/writing-tests.adoc b/documentation/src/docs/asciidoc/user-guide/writing-tests.adoc index 0c4f39c92816..de521fb12f09 100644 --- a/documentation/src/docs/asciidoc/user-guide/writing-tests.adoc +++ b/documentation/src/docs/asciidoc/user-guide/writing-tests.adoc @@ -1583,7 +1583,7 @@ _Parameterized tests_ make it possible to run a test method multiple times with arguments. They are declared just like regular `@Test` methods but use the `{ParameterizedTest}` annotation instead. -_Parameterized classes_ make it possible to run _all_ tests in test class, including +_Parameterized classes_ make it possible to run _all_ tests in a test class, including <>, multiple times with different arguments. They are declared just like regular test classes and may contain any supported test method type (including `@ParameterizedTest`) but annotated with the `{ParameterizedClass}` annotation. From 0e888626666847facdfef1aa4cfb8df5c7c53bc2 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Mon, 26 May 2025 15:18:33 +0200 Subject: [PATCH 004/109] Link to upgrade instructions wrt. GraalVM in the wiki (cherry picked from commit 87e3a7b64c07eae0af7ec13a2b8b598fe10b4c3a) --- .../release-notes/release-notes-5.13.0.adoc | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc index ea4319391681..35cb9c69ed32 100644 --- a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc +++ b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc @@ -30,11 +30,14 @@ repository on GitHub. [[release-notes-5.13.0-overall-new-features-and-improvements]] ==== Deprecations and Breaking Changes -* The JUnit feature in GraalVM Native Build Tools has been rewritten to no longer require - JUnit classes to be initialized at build time. Therefore, JUnit's JARs no longer ship - with `native-image.properties` files that contain `--initialize-at-build-time` options - (introduced in 5.12.0). Please update to the most recent version of GraalVM Native Build - Tools prior to upgrading to this version of JUnit. +* The JUnit feature in GraalVM Native Build Tools (NBT) has been rewritten to no longer + require JUnit classes to be initialized at build time when running on JDK 22 and later. + Therefore, JUnit's JARs no longer ship with `native-image.properties` files that contain + `--initialize-at-build-time` options (introduced in 5.12.0). Please update to the most + recent version of GraalVM Native Build Tools prior to upgrading to this version of + JUnit. Please refer to the + https://github.com/junit-team/junit5/wiki/Upgrading-to-JUnit-5.13[Upgrade Instructions] + in the wiki for details if you're on NBT 0.10.x or earlier. [[release-notes-5.13.0-junit-platform]] From 9e182d975dea259f957cc711e8d53df4529167ea Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Mon, 26 May 2025 15:19:05 +0200 Subject: [PATCH 005/109] Split list of `--initialize-at-build-time` classes by version (cherry picked from commit 27d9eae446d42a6aeb79b84d4fc512387863d551) --- .../projects/graalvm-starter/build.gradle.kts | 47 ++++++++++--------- .../graalvm-starter/settings.gradle.kts | 19 ++++++++ 2 files changed, 44 insertions(+), 22 deletions(-) diff --git a/platform-tooling-support-tests/projects/graalvm-starter/build.gradle.kts b/platform-tooling-support-tests/projects/graalvm-starter/build.gradle.kts index 7bdc3af69a56..9ae8736dd96f 100644 --- a/platform-tooling-support-tests/projects/graalvm-starter/build.gradle.kts +++ b/platform-tooling-support-tests/projects/graalvm-starter/build.gradle.kts @@ -7,11 +7,6 @@ val jupiterVersion: String by project val platformVersion: String by project val vintageVersion: String by project -repositories { - maven { url = uri(file(System.getProperty("maven.repo"))) } - mavenCentral() -} - dependencies { testImplementation("org.junit.jupiter:junit-jupiter:$jupiterVersion") testImplementation("junit:junit:4.13.2") @@ -34,29 +29,37 @@ tasks.test { } } -// These will be part of the next version of native-build-tools -// see https://github.com/graalvm/native-build-tools/pull/693 -val initializeAtBuildTime = listOf( - "org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor\$ClassInfo", - "org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor\$LifecycleMethods", - "org.junit.jupiter.engine.descriptor.ClassTemplateInvocationTestDescriptor", - "org.junit.jupiter.engine.descriptor.ClassTemplateTestDescriptor", - "org.junit.jupiter.engine.descriptor.DynamicDescendantFilter\$Mode", - "org.junit.jupiter.engine.descriptor.ExclusiveResourceCollector\$1", - "org.junit.jupiter.engine.descriptor.MethodBasedTestDescriptor\$MethodInfo", - "org.junit.jupiter.engine.discovery.ClassSelectorResolver\$DummyClassTemplateInvocationContext", - "org.junit.platform.launcher.core.DiscoveryIssueNotifier", - "org.junit.platform.launcher.core.HierarchicalOutputDirectoryProvider", - "org.junit.platform.launcher.core.LauncherDiscoveryResult\$EngineResultInfo", - "org.junit.platform.suite.engine.SuiteTestDescriptor\$LifecycleMethods", +val initializeAtBuildTime = mapOf( + // These will be part of the next version of native-build-tools + // see https://github.com/graalvm/native-build-tools/pull/693 + "5.13" to listOf( + "org.junit.jupiter.api.DisplayNameGenerator\$IndicativeSentences", + "org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor\$ClassInfo", + "org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor\$LifecycleMethods", + "org.junit.jupiter.engine.descriptor.ClassTemplateInvocationTestDescriptor", + "org.junit.jupiter.engine.descriptor.ClassTemplateTestDescriptor", + "org.junit.jupiter.engine.descriptor.DynamicDescendantFilter\$Mode", + "org.junit.jupiter.engine.descriptor.ExclusiveResourceCollector\$1", + "org.junit.jupiter.engine.descriptor.MethodBasedTestDescriptor\$MethodInfo", + "org.junit.jupiter.engine.discovery.ClassSelectorResolver\$DummyClassTemplateInvocationContext", + "org.junit.platform.engine.support.store.NamespacedHierarchicalStore\$EvaluatedValue", + "org.junit.platform.launcher.core.DiscoveryIssueNotifier", + "org.junit.platform.launcher.core.HierarchicalOutputDirectoryProvider", + "org.junit.platform.launcher.core.LauncherDiscoveryResult\$EngineResultInfo", + "org.junit.platform.suite.engine.SuiteTestDescriptor\$LifecycleMethods", + ), + // These need to be added to native-build-tools + "6.0" to listOf( + "org.junit.platform.commons.util.KotlinReflectionUtils", + "org.junit.platform.launcher.core.LauncherPhase", + ) ) graalvmNative { binaries { named("test") { - buildArgs.add("--strict-image-heap") buildArgs.add("-H:+ReportExceptionStackTraces") - buildArgs.add("--initialize-at-build-time=${initializeAtBuildTime.joinToString(",")}") + buildArgs.add("--initialize-at-build-time=${initializeAtBuildTime.values.flatten().joinToString(",")}") } } } diff --git a/platform-tooling-support-tests/projects/graalvm-starter/settings.gradle.kts b/platform-tooling-support-tests/projects/graalvm-starter/settings.gradle.kts index a53a82439ab6..5f62b311250c 100644 --- a/platform-tooling-support-tests/projects/graalvm-starter/settings.gradle.kts +++ b/platform-tooling-support-tests/projects/graalvm-starter/settings.gradle.kts @@ -6,6 +6,11 @@ pluginManagement { repositories { mavenCentral() gradlePluginPortal() + maven(url = "https://raw.githubusercontent.com/graalvm/native-build-tools/snapshots") { + mavenContent { + snapshotsOnly() + } + } } } @@ -13,4 +18,18 @@ plugins { id("org.gradle.toolchains.foojay-resolver-convention") version "0.10.0" } +dependencyResolutionManagement { + repositories { + repositories { + maven { url = uri(file(System.getProperty("maven.repo"))) } + mavenCentral() + maven(url = "https://raw.githubusercontent.com/graalvm/native-build-tools/snapshots") { + mavenContent { + snapshotsOnly() + } + } + } + } +} + rootProject.name = "graalvm-starter" From e616eb536250752a3112994376cd29b31fa869d8 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Mon, 26 May 2025 15:25:24 +0200 Subject: [PATCH 006/109] Move `LauncherPhase` to 5.13 list (cherry picked from commit b6636bbf107220927e289dca7145bf8f3dfa97d7) --- .../projects/graalvm-starter/build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform-tooling-support-tests/projects/graalvm-starter/build.gradle.kts b/platform-tooling-support-tests/projects/graalvm-starter/build.gradle.kts index 9ae8736dd96f..3b9eca6a830b 100644 --- a/platform-tooling-support-tests/projects/graalvm-starter/build.gradle.kts +++ b/platform-tooling-support-tests/projects/graalvm-starter/build.gradle.kts @@ -46,12 +46,12 @@ val initializeAtBuildTime = mapOf( "org.junit.platform.launcher.core.DiscoveryIssueNotifier", "org.junit.platform.launcher.core.HierarchicalOutputDirectoryProvider", "org.junit.platform.launcher.core.LauncherDiscoveryResult\$EngineResultInfo", + "org.junit.platform.launcher.core.LauncherPhase", "org.junit.platform.suite.engine.SuiteTestDescriptor\$LifecycleMethods", ), // These need to be added to native-build-tools "6.0" to listOf( "org.junit.platform.commons.util.KotlinReflectionUtils", - "org.junit.platform.launcher.core.LauncherPhase", ) ) From 33422ad0afa52dddaae30a66cb553bb47784bc8d Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Mon, 26 May 2025 15:36:51 +0200 Subject: [PATCH 007/109] Test against snapshot version of native-build-tools In order to catch classes missing after the refactoring (cherry picked from commit 67c357c578cfbb0bbce2980e39d69ae4754d7342) --- .../projects/graalvm-starter/settings.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform-tooling-support-tests/projects/graalvm-starter/settings.gradle.kts b/platform-tooling-support-tests/projects/graalvm-starter/settings.gradle.kts index 5f62b311250c..2bdae59795e2 100644 --- a/platform-tooling-support-tests/projects/graalvm-starter/settings.gradle.kts +++ b/platform-tooling-support-tests/projects/graalvm-starter/settings.gradle.kts @@ -1,7 +1,7 @@ pluginManagement { plugins { // TODO Remove custom config in build.gradle.kts when upgrading - id("org.graalvm.buildtools.native") version "0.10.6" + id("org.graalvm.buildtools.native") version "0.11.0-SNAPSHOT" } repositories { mavenCentral() From 9f8b6e22ff8b7777aaacd3ea39224522dc611ee8 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Mon, 26 May 2025 15:37:11 +0200 Subject: [PATCH 008/109] Add two missing classes from junit-platform-suite-engine (cherry picked from commit f8ae3397383399f4f1297db1525daa7c20697f66) --- .../projects/graalvm-starter/build.gradle.kts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/platform-tooling-support-tests/projects/graalvm-starter/build.gradle.kts b/platform-tooling-support-tests/projects/graalvm-starter/build.gradle.kts index 3b9eca6a830b..a54c88d2c9f3 100644 --- a/platform-tooling-support-tests/projects/graalvm-starter/build.gradle.kts +++ b/platform-tooling-support-tests/projects/graalvm-starter/build.gradle.kts @@ -47,6 +47,8 @@ val initializeAtBuildTime = mapOf( "org.junit.platform.launcher.core.HierarchicalOutputDirectoryProvider", "org.junit.platform.launcher.core.LauncherDiscoveryResult\$EngineResultInfo", "org.junit.platform.launcher.core.LauncherPhase", + "org.junit.platform.suite.engine.DiscoverySelectorResolver", + "org.junit.platform.suite.engine.SuiteTestDescriptor\$DiscoveryIssueForwardingListener", "org.junit.platform.suite.engine.SuiteTestDescriptor\$LifecycleMethods", ), // These need to be added to native-build-tools From d666d8236390ab0e01858e6c41045e1bf0238a6c Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Tue, 27 May 2025 09:17:32 +0200 Subject: [PATCH 009/109] Make dependency on open-test-reporting-tooling-spi non-optional Since the module descriptor requires it, it cannot be optional but must be a regular dependency. Otherwise, using junit-platform-reporting on the module path will fail. (cherry picked from commit e886149a723ba7533d4e7b8ca1a767a77942c277) --- junit-platform-reporting/junit-platform-reporting.gradle.kts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/junit-platform-reporting/junit-platform-reporting.gradle.kts b/junit-platform-reporting/junit-platform-reporting.gradle.kts index 5f11aab2adf9..bdd634f7f4c8 100644 --- a/junit-platform-reporting/junit-platform-reporting.gradle.kts +++ b/junit-platform-reporting/junit-platform-reporting.gradle.kts @@ -12,8 +12,9 @@ dependencies { api(platform(projects.junitBom)) api(projects.junitPlatformLauncher) + implementation(libs.openTestReporting.tooling.spi) + compileOnlyApi(libs.apiguardian) - compileOnlyApi(libs.openTestReporting.tooling.spi) shadowed(libs.openTestReporting.events) From 7ef1f6b011edfbd67796eb564971ba3394498ff5 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Tue, 27 May 2025 09:17:59 +0200 Subject: [PATCH 010/109] Remove junit-platform-reporting from `reflection-tests` (cherry picked from commit cbb95ecfe9914fcb563c931febd924bb7717c9bb) --- .../projects/reflection-tests/build.gradle.kts | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/platform-tooling-support-tests/projects/reflection-tests/build.gradle.kts b/platform-tooling-support-tests/projects/reflection-tests/build.gradle.kts index 0dea5aab80a1..5887441a08ee 100644 --- a/platform-tooling-support-tests/projects/reflection-tests/build.gradle.kts +++ b/platform-tooling-support-tests/projects/reflection-tests/build.gradle.kts @@ -13,7 +13,7 @@ repositories { dependencies { testImplementation("org.junit.jupiter:junit-jupiter:$jupiterVersion") testImplementation("org.junit.jupiter:junit-jupiter-engine:$jupiterVersion") - testRuntimeOnly("org.junit.platform:junit-platform-reporting:$platformVersion") + testRuntimeOnly("org.junit.platform:junit-platform-launcher:$platformVersion") } java { @@ -32,12 +32,4 @@ tasks.test { reports { html.required = true } - - val outputDir = reports.junitXml.outputLocation - jvmArgumentProviders += CommandLineArgumentProvider { - listOf( - "-Djunit.platform.reporting.open.xml.enabled=true", - "-Djunit.platform.reporting.output.dir=${outputDir.get().asFile.absolutePath}" - ) - } } From 182a268a8a38cd4047f80e6478f8896f0595e027 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Tue, 27 May 2025 09:04:38 +0200 Subject: [PATCH 011/109] Force Gradle to update snapshots (cherry picked from commit af1242ea9ef353ab83ad5f21ca6721afe808bb04) --- .../platform/tooling/support/tests/GraalVmStarterTests.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform-tooling-support-tests/src/test/java/platform/tooling/support/tests/GraalVmStarterTests.java b/platform-tooling-support-tests/src/test/java/platform/tooling/support/tests/GraalVmStarterTests.java index e74c1400bd9c..560ec627068e 100644 --- a/platform-tooling-support-tests/src/test/java/platform/tooling/support/tests/GraalVmStarterTests.java +++ b/platform-tooling-support-tests/src/test/java/platform/tooling/support/tests/GraalVmStarterTests.java @@ -50,7 +50,7 @@ void runsTestsInNativeImage(@TempDir Path workspace, @FilePrefix("gradle") Outpu graalVmHome.orElseThrow(TestAbortedException::new).toString()).addArguments( "-Dmaven.repo=" + MavenRepo.dir()) // .addArguments("javaToolchains", "nativeTest", "--no-daemon", "--stacktrace", "--no-build-cache", - "--warning-mode=fail") // + "--warning-mode=fail", "--refresh-dependencies") // .redirectOutput(outputFiles) // .startAndWait(); From df466515d250c7f041aed13890f0490c8497680d Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Tue, 27 May 2025 09:38:32 +0200 Subject: [PATCH 012/109] Fix `:junit-platform-console:compileModule` --- junit-platform-console/junit-platform-console.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/junit-platform-console/junit-platform-console.gradle.kts b/junit-platform-console/junit-platform-console.gradle.kts index 7a032e5ae482..d31b5ca14cc9 100644 --- a/junit-platform-console/junit-platform-console.gradle.kts +++ b/junit-platform-console/junit-platform-console.gradle.kts @@ -16,12 +16,12 @@ dependencies { compileOnlyApi(libs.apiguardian) compileOnly(libs.openTestReporting.events) + compileOnly(libs.openTestReporting.tooling.spi) shadowed(libs.picocli) osgiVerification(projects.junitJupiterEngine) osgiVerification(projects.junitPlatformLauncher) - osgiVerification(libs.openTestReporting.tooling.spi) } tasks { From b819306bccb1ab78994a208169d9e98ca97e7a5b Mon Sep 17 00:00:00 2001 From: Christian Stein Date: Tue, 27 May 2025 15:40:47 +0200 Subject: [PATCH 013/109] Fix console launcher's `--uid` option (#4589) Prior to this commit, unique id selectors weren't included in the list of explicit selectors - which resulted a false error message: ``` Please specify an explicit selector option or use `--scan-class-path` or `--scan-modules` ``` Fixes #4587 --------- Co-authored-by: Marc Philipp (cherry picked from commit fa3c065741593123d359bcd20c81067301a5021b) --- .../release-notes/release-notes-5.13.0.adoc | 1 + .../asciidoc/user-guide/running-tests.adoc | 2 +- .../console/options/TestDiscoveryOptions.java | 1 + .../tasks/DiscoveryRequestCreatorTests.java | 18 ++++++++++++++++++ 4 files changed, 21 insertions(+), 1 deletion(-) diff --git a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc index 35cb9c69ed32..35efebf70ac0 100644 --- a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc +++ b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc @@ -52,6 +52,7 @@ repository on GitHub. the `ConsoleLauncher`. Prior to this release, the created class loader was closed prior to JVM shutdown hooks being invoked, which caused hooks to fail with a `ClassNotFoundException` when loading classes during shutdown. +* Fix support of `--uid` and `--select-unique-id` options in the console launcher. [[release-notes-5.13.0-junit-platform-deprecations-and-breaking-changes]] ==== Deprecations and Breaking Changes diff --git a/documentation/src/docs/asciidoc/user-guide/running-tests.adoc b/documentation/src/docs/asciidoc/user-guide/running-tests.adoc index f3568ade9a31..5830ac9e8f42 100644 --- a/documentation/src/docs/asciidoc/user-guide/running-tests.adoc +++ b/documentation/src/docs/asciidoc/user-guide/running-tests.adoc @@ -997,7 +997,7 @@ The following discovery selectors are provided out of the box: | `{NestedClassSelector}` | `{DiscoverySelectors_selectNestedClass}` | `{Select}("")` | `--select ` | `nested-class:com.acme.Foo/Bar` | `{NestedMethodSelector}` | `{DiscoverySelectors_selectNestedMethod}` | `{Select}("")` | `--select ` | `nested-method:com.acme.Foo/Bar#m` | `{PackageSelector}` | `{DiscoverySelectors_selectPackage}` | `{SelectPackages}` | `--select-package com.acme.foo` | `package:com.acme.foo` -| `{UniqueIdSelector}` | `{DiscoverySelectors_selectUniqueId}` | `{Select}("")` | `--select ` | `uid:...` +| `{UniqueIdSelector}` | `{DiscoverySelectors_selectUniqueId}` | `{Select}("")` | `--select-unique-id ` | `uid:[engine:Foo]/[segment:Bar]` | `{UriSelector}` | `{DiscoverySelectors_selectUri}` | `{SelectUris}` | `--select-uri \file:///foo.txt` | `uri:file:///foo.txt` |=== diff --git a/junit-platform-console/src/main/java/org/junit/platform/console/options/TestDiscoveryOptions.java b/junit-platform-console/src/main/java/org/junit/platform/console/options/TestDiscoveryOptions.java index 0345dde65603..24ca54b669dd 100644 --- a/junit-platform-console/src/main/java/org/junit/platform/console/options/TestDiscoveryOptions.java +++ b/junit-platform-console/src/main/java/org/junit/platform/console/options/TestDiscoveryOptions.java @@ -202,6 +202,7 @@ public void setSelectorIdentifiers(List selectorIde public List getExplicitSelectors() { List selectors = new ArrayList<>(); + selectors.addAll(getSelectedUniqueIds()); selectors.addAll(getSelectedUris()); selectors.addAll(getSelectedFiles()); selectors.addAll(getSelectedDirectories()); diff --git a/platform-tests/src/test/java/org/junit/platform/console/tasks/DiscoveryRequestCreatorTests.java b/platform-tests/src/test/java/org/junit/platform/console/tasks/DiscoveryRequestCreatorTests.java index e1ec970f3ecd..f9a2bcb97c50 100644 --- a/platform-tests/src/test/java/org/junit/platform/console/tasks/DiscoveryRequestCreatorTests.java +++ b/platform-tests/src/test/java/org/junit/platform/console/tasks/DiscoveryRequestCreatorTests.java @@ -22,6 +22,7 @@ import static org.junit.platform.engine.discovery.DiscoverySelectors.selectIteration; import static org.junit.platform.engine.discovery.DiscoverySelectors.selectMethod; import static org.junit.platform.engine.discovery.DiscoverySelectors.selectPackage; +import static org.junit.platform.engine.discovery.DiscoverySelectors.selectUniqueId; import static org.junit.platform.engine.discovery.DiscoverySelectors.selectUri; import java.io.File; @@ -36,6 +37,7 @@ import org.junit.platform.commons.PreconditionViolationException; import org.junit.platform.console.options.TestDiscoveryOptions; import org.junit.platform.engine.Filter; +import org.junit.platform.engine.UniqueId; import org.junit.platform.engine.discovery.ClassNameFilter; import org.junit.platform.engine.discovery.ClassSelector; import org.junit.platform.engine.discovery.ClasspathResourceSelector; @@ -46,6 +48,7 @@ import org.junit.platform.engine.discovery.MethodSelector; import org.junit.platform.engine.discovery.PackageNameFilter; import org.junit.platform.engine.discovery.PackageSelector; +import org.junit.platform.engine.discovery.UniqueIdSelector; import org.junit.platform.engine.discovery.UriSelector; import org.junit.platform.launcher.LauncherDiscoveryRequest; @@ -218,6 +221,21 @@ void convertsEngineOptions() { assertThat(engineFilters.get(1).toString()).contains("excludes", "[engine2]"); } + @Test + void propagatesUniqueIdSelectors() { + options.setSelectedUniqueId(List.of(selectUniqueId("[engine:a]/[1:1]"), selectUniqueId("[engine:b]/[2:2]"))); + + var request = convert(); + var uriSelectors = request.getSelectorsByType(UniqueIdSelector.class); + + assertThat(uriSelectors) // + .extracting(UniqueIdSelector::getUniqueId) // + .containsExactly( // + UniqueId.parse("[engine:a]/[1:1]"), //, // + UniqueId.parse("[engine:b]/[2:2]") // + ); + } + @Test void propagatesUriSelectors() { options.setSelectedUris(List.of(selectUri("a"), selectUri("b"))); From 4b27910013e672e2c55c26a1ab7737d0ac1f321e Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Wed, 28 May 2025 12:56:00 +0200 Subject: [PATCH 014/109] Allow publishing files to an existing directory Prior to this commit, both `TestReporter` and `ExtensionContext` threw an exception when `publishDirectory` was called with an existing directory. Now, they only attempt to create the directory if it doesn't already exist. (cherry picked from commit acc638509baaf973c738b569cea694ce17c460d2) --- .../release-notes/release-notes-5.13.0.adoc | 2 ++ .../jupiter/api/extension/ExtensionContext.java | 2 +- .../engine/descriptor/AbstractExtensionContext.java | 4 +++- .../engine/descriptor/ExtensionContextTests.java | 13 +++++++++++++ 4 files changed, 19 insertions(+), 2 deletions(-) diff --git a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc index 35efebf70ac0..11135967b332 100644 --- a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc +++ b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc @@ -188,6 +188,8 @@ to start reporting discovery issues. failures. * Add support for Kotlin `Sequence` to `@MethodSource`, `@FieldSource`, and `@TestFactory`. +* Allow publishing files to an existing directory via `TestReporter` and + `ExtensionContext`, for example, when re-running a test class. [[release-notes-5.13.0-junit-vintage]] diff --git a/junit-jupiter-api/src/main/java/org/junit/jupiter/api/extension/ExtensionContext.java b/junit-jupiter-api/src/main/java/org/junit/jupiter/api/extension/ExtensionContext.java index 1f1eeda903f4..0f9122024e87 100644 --- a/junit-jupiter-api/src/main/java/org/junit/jupiter/api/extension/ExtensionContext.java +++ b/junit-jupiter-api/src/main/java/org/junit/jupiter/api/extension/ExtensionContext.java @@ -420,7 +420,7 @@ default void publishReportEntry(String value) { * and attach it to the current test or container. * *

The directory will be resolved and created in the report output directory - * prior to invoking the supplied action. + * prior to invoking the supplied action, if it doesn't already exist. * * @param name the name of the directory to be attached; never {@code null} * or blank and must not contain any path separators diff --git a/junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/descriptor/AbstractExtensionContext.java b/junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/descriptor/AbstractExtensionContext.java index 219acbb474c7..5aafcc1103e3 100644 --- a/junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/descriptor/AbstractExtensionContext.java +++ b/junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/descriptor/AbstractExtensionContext.java @@ -159,7 +159,9 @@ public void publishDirectory(String name, ThrowingConsumer action) { Preconditions.notNull(action, "action must not be null"); ThrowingConsumer enhancedAction = path -> { - Files.createDirectory(path); + if (!Files.isDirectory(path)) { + Files.createDirectory(path); + } action.accept(path); }; publishFileEntry(name, enhancedAction, file -> { diff --git a/jupiter-tests/src/test/java/org/junit/jupiter/engine/descriptor/ExtensionContextTests.java b/jupiter-tests/src/test/java/org/junit/jupiter/engine/descriptor/ExtensionContextTests.java index 2417b145c380..8ff77a8fe4ef 100644 --- a/jupiter-tests/src/test/java/org/junit/jupiter/engine/descriptor/ExtensionContextTests.java +++ b/jupiter-tests/src/test/java/org/junit/jupiter/engine/descriptor/ExtensionContextTests.java @@ -374,6 +374,19 @@ void failsWhenAttemptingToPublishRegularFilesAsDirectories(@TempDir Path tempDir "Published path must be a directory: " + tempDir.resolve("OuterClass").resolve("test")); } + @Test + void allowsPublishingToTheSameDirectoryTwice(@TempDir Path tempDir) { + var extensionContext = createExtensionContextForFilePublishing(tempDir); + + extensionContext.publishDirectory("test", + dir -> Files.writeString(dir.resolve("nested1.txt"), "Nested content 1")); + extensionContext.publishDirectory("test", + dir -> Files.writeString(dir.resolve("nested2.txt"), "Nested content 2")); + + assertThat(tempDir.resolve("OuterClass/test/nested1.txt")).hasContent("Nested content 1"); + assertThat(tempDir.resolve("OuterClass/test/nested2.txt")).hasContent("Nested content 2"); + } + private ExtensionContext createExtensionContextForFilePublishing(Path tempDir) { return createExtensionContextForFilePublishing(tempDir, mock(EngineExecutionListener.class), outerClassDescriptor(null)); From 2c86dfa055d679d203f0977b0739a385cc2649d1 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Thu, 29 May 2025 11:03:51 +0200 Subject: [PATCH 015/109] Avoid publishing Gradle Module Metadata for `shadowRuntimeElements` --- .../src/main/kotlin/junitbuild.shadow-conventions.gradle.kts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gradle/plugins/common/src/main/kotlin/junitbuild.shadow-conventions.gradle.kts b/gradle/plugins/common/src/main/kotlin/junitbuild.shadow-conventions.gradle.kts index ed1732e00e78..5a3c40d23cc3 100644 --- a/gradle/plugins/common/src/main/kotlin/junitbuild.shadow-conventions.gradle.kts +++ b/gradle/plugins/common/src/main/kotlin/junitbuild.shadow-conventions.gradle.kts @@ -44,6 +44,9 @@ idea { } } +val javaComponent = components["java"] as AdhocComponentWithVariants +javaComponent.withVariantsFromConfiguration(configurations.shadowRuntimeElements.get()) { skip() } + tasks { javadoc { classpath += shadowedClasspath.get() From 36bb005e4d28f3c817a0f3c1466603a84deeb841 Mon Sep 17 00:00:00 2001 From: Sam Brannen <104798+sbrannen@users.noreply.github.com> Date: Thu, 29 May 2025 17:40:21 +0200 Subject: [PATCH 016/109] Improve assertion failure message in TestClassPredicatesTests The recursiveHierarchies() test currently fails when running in Eclipse IDE, but the failure message does not indicate what the expected message is for the expected JUnitException. This commit therefore updates the assertion to check the exception message to help with diagnostics. (cherry picked from commit 3c5b457564d559fb0f396d7f303f8effe291daa3) --- .../discovery/predicates/TestClassPredicatesTests.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/jupiter-tests/src/test/java/org/junit/jupiter/engine/discovery/predicates/TestClassPredicatesTests.java b/jupiter-tests/src/test/java/org/junit/jupiter/engine/discovery/predicates/TestClassPredicatesTests.java index 757d4a8cfa6c..30ea70b31b54 100644 --- a/jupiter-tests/src/test/java/org/junit/jupiter/engine/discovery/predicates/TestClassPredicatesTests.java +++ b/jupiter-tests/src/test/java/org/junit/jupiter/engine/discovery/predicates/TestClassPredicatesTests.java @@ -11,8 +11,8 @@ package org.junit.jupiter.engine.discovery.predicates; import static org.assertj.core.api.Assertions.assertThat; +import static org.assertj.core.api.Assertions.assertThatExceptionOfType; import static org.junit.jupiter.api.Assertions.assertFalse; -import static org.junit.jupiter.api.Assertions.assertThrows; import static org.junit.jupiter.api.Assertions.assertTrue; import java.util.ArrayList; @@ -218,7 +218,11 @@ void privateStaticTestClassEvaluatesToFalse() { */ @Test void recursiveHierarchies() { - assertThrows(JUnitException.class, () -> predicates.looksLikeIntendedTestClass(TestCases.OuterClass.class)); + assertThatExceptionOfType(JUnitException.class)// + .isThrownBy(() -> predicates.looksLikeIntendedTestClass(TestCases.OuterClass.class))// + .withMessage("Detected cycle in inner class hierarchy between %s and %s", + TestCases.OuterClass.RecursiveInnerClass.class.getName(), TestCases.OuterClass.class.getName()); + assertTrue(predicates.isValidStandaloneTestClass(TestCases.OuterClass.class)); assertThat(discoveryIssues).isEmpty(); @@ -404,6 +408,7 @@ void test() { @SuppressWarnings("InnerClassMayBeStatic") class RecursiveInnerClass extends OuterClass { } + } private static class NestedClassesTestCase { From 5f0e4e6e355355693eddac376669be393476dc66 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Fri, 30 May 2025 11:07:44 +0200 Subject: [PATCH 017/109] Remove short-circuiting to ensure all classes are checked for cycles (#4598) Resolves #4597. (cherry picked from commit 8387b448a4b92694be42ab74873ba5934cb7dd24) --- .../commons/util/ReflectionUtils.java | 50 +++++++------------ 1 file changed, 17 insertions(+), 33 deletions(-) diff --git a/junit-platform-commons/src/main/java/org/junit/platform/commons/util/ReflectionUtils.java b/junit-platform-commons/src/main/java/org/junit/platform/commons/util/ReflectionUtils.java index f122e8c77958..a79c7c9cce26 100644 --- a/junit-platform-commons/src/main/java/org/junit/platform/commons/util/ReflectionUtils.java +++ b/junit-platform-commons/src/main/java/org/junit/platform/commons/util/ReflectionUtils.java @@ -52,6 +52,8 @@ import java.util.Optional; import java.util.Set; import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.atomic.AtomicBoolean; +import java.util.function.Consumer; import java.util.function.Predicate; import java.util.regex.Matcher; import java.util.regex.Pattern; @@ -1236,10 +1238,7 @@ public static List> findNestedClasses(Class clazz, Predicate> candidates = new LinkedHashSet<>(); - visitNestedClasses(clazz, predicate, nestedClass -> { - candidates.add(nestedClass); - return true; - }); + visitAllNestedClasses(clazz, predicate, candidates::add); return Collections.unmodifiableList(new ArrayList<>(candidates)); } @@ -1261,8 +1260,9 @@ public static boolean isNestedClassPresent(Class clazz, Predicate> p Preconditions.notNull(clazz, "Class must not be null"); Preconditions.notNull(predicate, "Predicate must not be null"); - boolean visitorWasNotCalled = visitNestedClasses(clazz, predicate, __ -> false); - return !visitorWasNotCalled; + AtomicBoolean foundNestedClass = new AtomicBoolean(false); + visitAllNestedClasses(clazz, predicate, __ -> foundNestedClass.setPlain(true)); + return foundNestedClass.getPlain(); } /** @@ -1273,10 +1273,15 @@ public static Stream> streamNestedClasses(Class clazz, Predicate clazz, Predicate> predicate, - Visitor> visitor) { + /** + * Visit all nested classes without support for short-circuiting + * in order to ensure all of them are checked for class cycles. + */ + private static void visitAllNestedClasses(Class clazz, Predicate> predicate, + Consumer> consumer) { + if (!isSearchable(clazz)) { - return true; + return; } if (isInnerClass(clazz) && predicate.test(clazz)) { @@ -1288,10 +1293,7 @@ private static boolean visitNestedClasses(Class clazz, Predicate> pr for (Class nestedClass : clazz.getDeclaredClasses()) { if (predicate.test(nestedClass)) { detectInnerClassCycle(nestedClass); - boolean shouldContinue = visitor.accept(nestedClass); - if (!shouldContinue) { - return false; - } + consumer.accept(nestedClass); } } } @@ -1300,20 +1302,12 @@ private static boolean visitNestedClasses(Class clazz, Predicate> pr } // Search class hierarchy - boolean shouldContinue = visitNestedClasses(clazz.getSuperclass(), predicate, visitor); - if (!shouldContinue) { - return false; - } + visitAllNestedClasses(clazz.getSuperclass(), predicate, consumer); // Search interface hierarchy for (Class ifc : clazz.getInterfaces()) { - shouldContinue = visitNestedClasses(ifc, predicate, visitor); - if (!shouldContinue) { - return false; - } + visitAllNestedClasses(ifc, predicate, consumer); } - - return true; } /** @@ -2119,14 +2113,4 @@ private static boolean getLegacySearchSemanticsFlag() { return isTrue; } - private interface Visitor { - - /** - * @return {@code true} if the visitor should continue searching; - * {@code false} if the visitor should stop - */ - boolean accept(T value); - - } - } From 9bb6a0f4bdb63709a86410e695e0fb31b79aaa28 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Fri, 30 May 2025 11:09:08 +0200 Subject: [PATCH 018/109] Finalize 5.13.0 release notes (cherry picked from commit 2eaf488b7be163d7842f09bce6f988ccc15d44d7) --- .../asciidoc/release-notes/release-notes-5.13.0.adoc | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc index 11135967b332..c8a7dfa56ab2 100644 --- a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc +++ b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.0.adoc @@ -54,11 +54,6 @@ repository on GitHub. `ClassNotFoundException` when loading classes during shutdown. * Fix support of `--uid` and `--select-unique-id` options in the console launcher. -[[release-notes-5.13.0-junit-platform-deprecations-and-breaking-changes]] -==== Deprecations and Breaking Changes - -* ❓ - [[release-notes-5.13.0-junit-platform-new-features-and-improvements]] ==== New Features and Improvements @@ -116,11 +111,6 @@ to start reporting discovery issues. failure happens prior to invoking the parameterized method. * Validate _all_ versions specified in `@EnabledOnJre` and `@DisabledOnJre` annotations. -[[release-notes-5.13.0-junit-jupiter-deprecations-and-breaking-changes]] -==== Deprecations and Breaking Changes - -* ❓ - [[release-notes-5.13.0-junit-jupiter-new-features-and-improvements]] ==== New Features and Improvements From a54ad65325608225e553b8c1310899f090fdf8eb Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Fri, 30 May 2025 11:17:12 +0200 Subject: [PATCH 019/109] Use `set`/`get` on `AtomicBoolean` compatibility with Java 8 --- .../java/org/junit/platform/commons/util/ReflectionUtils.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/junit-platform-commons/src/main/java/org/junit/platform/commons/util/ReflectionUtils.java b/junit-platform-commons/src/main/java/org/junit/platform/commons/util/ReflectionUtils.java index a79c7c9cce26..4e1c359b4b5f 100644 --- a/junit-platform-commons/src/main/java/org/junit/platform/commons/util/ReflectionUtils.java +++ b/junit-platform-commons/src/main/java/org/junit/platform/commons/util/ReflectionUtils.java @@ -1261,8 +1261,8 @@ public static boolean isNestedClassPresent(Class clazz, Predicate> p Preconditions.notNull(predicate, "Predicate must not be null"); AtomicBoolean foundNestedClass = new AtomicBoolean(false); - visitAllNestedClasses(clazz, predicate, __ -> foundNestedClass.setPlain(true)); - return foundNestedClass.getPlain(); + visitAllNestedClasses(clazz, predicate, __ -> foundNestedClass.set(true)); + return foundNestedClass.get(); } /** From f539f92fce67e95c642e3788284e27dbad8add7c Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Fri, 30 May 2025 12:00:25 +0200 Subject: [PATCH 020/109] Release 5.13.0 --- README.md | 2 +- gradle.properties | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 20f691ec93f5..4f6249075d16 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ This repository is the home of _JUnit 5_. ## Latest Releases -- General Availability (GA): [JUnit 5.12.2](https://github.com/junit-team/junit5/releases/tag/r5.12.2) (April 11, 2025) +- General Availability (GA): [JUnit 5.13.0](https://github.com/junit-team/junit5/releases/tag/r5.13.0) (May 30, 2025) - Preview (Milestone/Release Candidate): [JUnit 5.13.0-RC1](https://github.com/junit-team/junit5/releases/tag/r5.13.0-RC1) (May 16, 2025) ## Documentation diff --git a/gradle.properties b/gradle.properties index 1f57336a6a6a..82f60e414f01 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,13 +1,13 @@ group = org.junit -version = 5.13.0-SNAPSHOT +version = 5.13.0 jupiterGroup = org.junit.jupiter platformGroup = org.junit.platform -platformVersion = 1.13.0-SNAPSHOT +platformVersion = 1.13.0 vintageGroup = org.junit.vintage -vintageVersion = 5.13.0-SNAPSHOT +vintageVersion = 5.13.0 # We need more metaspace due to apparent memory leak in Asciidoctor/JRuby org.gradle.jvmargs=-Xmx1g -XX:MaxMetaspaceSize=512m -XX:+HeapDumpOnOutOfMemoryError From d7c82165dde2b58bdf2442f1824ae15010fcf297 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Fri, 30 May 2025 12:04:11 +0200 Subject: [PATCH 021/109] Back to snapshots for further development --- gradle.properties | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gradle.properties b/gradle.properties index 82f60e414f01..235ab09ed115 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,13 +1,13 @@ group = org.junit -version = 5.13.0 +version = 5.13.1-SNAPSHOT jupiterGroup = org.junit.jupiter platformGroup = org.junit.platform -platformVersion = 1.13.0 +platformVersion = 1.13.1-SNAPSHOT vintageGroup = org.junit.vintage -vintageVersion = 5.13.0 +vintageVersion = 5.13.1-SNAPSHOT # We need more metaspace due to apparent memory leak in Asciidoctor/JRuby org.gradle.jvmargs=-Xmx1g -XX:MaxMetaspaceSize=512m -XX:+HeapDumpOnOutOfMemoryError From 6a7998b136173a0bb89c00407cb7b6d78d0778f0 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Fri, 30 May 2025 12:18:15 +0200 Subject: [PATCH 022/109] Revert "Don't error on already closed milestones" This reverts commit 52ae1126 --- .github/workflows/release.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 09ed237ade58..d1a91be83ec8 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -119,12 +119,12 @@ jobs: with: result-encoding: string script: | - const milestones = await github.rest.issues.listMilestones({ + const openMilestones = await github.rest.issues.listMilestones({ owner: context.repo.owner, repo: context.repo.repo, - state: 'all' + state: 'open' }); - const [milestone] = milestones.data.filter(x => x.title === "${{ inputs.releaseVersion }}") + const [milestone] = openMilestones.data.filter(x => x.title === "${{ inputs.releaseVersion }}") if (!milestone) { throw new Error('Milestone "${{ inputs.releaseVersion }}" not found'); } From 3447d713ef2222a4942b082f66d76af393d4536d Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Fri, 30 May 2025 13:46:33 +0200 Subject: [PATCH 023/109] Update supported versions --- SECURITY.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SECURITY.md b/SECURITY.md index 4d4bad5f6641..90102e191264 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -11,8 +11,8 @@ You'll find more information about the key here: [KEYS](./KEYS) | Version | Supported | |---------| ------------------ | -| 5.12.x | :white_check_mark: | -| < 5.12 | :x: | +| 5.13.x | :white_check_mark: | +| < 5.13 | :x: | ## Reporting a Vulnerability From 2d58467d717c0e39fde9dc752ebd1682ec789d68 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Sat, 31 May 2025 09:55:02 +0200 Subject: [PATCH 024/109] Create initial 5.13.1 release notes from template (cherry picked from commit 0e2ff3a7f2a74823d49352d8c96b651c33d2c380) --- .../docs/asciidoc/release-notes/index.adoc | 2 + .../release-notes/release-notes-5.13.1.adoc | 67 +++++++++++++++++++ 2 files changed, 69 insertions(+) create mode 100644 documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc diff --git a/documentation/src/docs/asciidoc/release-notes/index.adoc b/documentation/src/docs/asciidoc/release-notes/index.adoc index 9fd3e2b75ae9..62d53b05257e 100644 --- a/documentation/src/docs/asciidoc/release-notes/index.adoc +++ b/documentation/src/docs/asciidoc/release-notes/index.adoc @@ -17,6 +17,8 @@ authors as well as build tool and IDE vendors. include::{includedir}/link-attributes.adoc[] +include::{basedir}/release-notes-5.13.1.adoc[] + include::{basedir}/release-notes-5.13.0.adoc[] include::{basedir}/release-notes-5.12.2.adoc[] diff --git a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc new file mode 100644 index 000000000000..abb783ac56e4 --- /dev/null +++ b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc @@ -0,0 +1,67 @@ +[[release-notes-5.13.1]] +== 5.13.1 + +*Date of Release:* ❓ + +*Scope:* ❓ + +For a complete list of all _closed_ issues and pull requests for this release, consult the +link:{junit5-repo}+/milestone/97?closed=1+[5.13.1] milestone page in the JUnit repository +on GitHub. + + +[[release-notes-5.13.1-junit-platform]] +=== JUnit Platform + +[[release-notes-5.13.1-junit-platform-bug-fixes]] +==== Bug Fixes + +* ❓ + +[[release-notes-5.13.1-junit-platform-deprecations-and-breaking-changes]] +==== Deprecations and Breaking Changes + +* ❓ + +[[release-notes-5.13.1-junit-platform-new-features-and-improvements]] +==== New Features and Improvements + +* ❓ + + +[[release-notes-5.13.1-junit-jupiter]] +=== JUnit Jupiter + +[[release-notes-5.13.1-junit-jupiter-bug-fixes]] +==== Bug Fixes + +* ❓ + +[[release-notes-5.13.1-junit-jupiter-deprecations-and-breaking-changes]] +==== Deprecations and Breaking Changes + +* ❓ + +[[release-notes-5.13.1-junit-jupiter-new-features-and-improvements]] +==== New Features and Improvements + +* ❓ + + +[[release-notes-5.13.1-junit-vintage]] +=== JUnit Vintage + +[[release-notes-5.13.1-junit-vintage-bug-fixes]] +==== Bug Fixes + +* ❓ + +[[release-notes-5.13.1-junit-vintage-deprecations-and-breaking-changes]] +==== Deprecations and Breaking Changes + +* ❓ + +[[release-notes-5.13.1-junit-vintage-new-features-and-improvements]] +==== New Features and Improvements + +* ❓ From a866c0169d5254a67b561a652c757b24f45859f0 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Wed, 4 Jun 2025 11:44:16 +0200 Subject: [PATCH 025/109] Ensure `@Nested` classes are executed after sibling test methods (#4603) In order to validate them, classpath scanning was changed to find them in 5.13.0. However, that caused `@Nested` classes to be added to their parent descriptors before their sibling test methods. This made the order of execution in classes containing nested test classes dependent on how they were discovered unless a `MethodOrderer` was configured in which case `MethodOrderingVisitor` ensured test methods came before `@Nested` test classes on the same level. This commit changes `MethodOrderingVisitor` to also ensure this ordering constraint in case no `MethodOrderer` is configured. Resolves #4600. (cherry picked from commit d0d6071a368aaa945307d27cfad7de8d3f3b6e8d) --- .../release-notes/release-notes-5.13.1.adoc | 8 ++++- .../discovery/MethodOrderingVisitor.java | 20 +++++++++++ .../engine/NestedTestClassesTests.java | 34 ++++++++++++++++--- 3 files changed, 56 insertions(+), 6 deletions(-) diff --git a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc index abb783ac56e4..505bdb10b39b 100644 --- a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc +++ b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc @@ -35,7 +35,13 @@ on GitHub. [[release-notes-5.13.1-junit-jupiter-bug-fixes]] ==== Bug Fixes -* ❓ +* The 5.13.0 release introduced a regression regarding the execution order in test classes + containing both test methods and `@Nested` test classes. When classpath scanning was + used during test discovery -- for example, when resolving a package selector for a + `@Suite` class -- test methods in `@Nested` classes were executed _before_ test methods + in their enclosing class. This undesired change in behavior has now been reverted so + that tests in `@Nested` test classes are always executed _after_ tests in enclosing test + classes again. [[release-notes-5.13.1-junit-jupiter-deprecations-and-breaking-changes]] ==== Deprecations and Breaking Changes diff --git a/junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/discovery/MethodOrderingVisitor.java b/junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/discovery/MethodOrderingVisitor.java index 471b9ecf8368..48a3d4c8228f 100644 --- a/junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/discovery/MethodOrderingVisitor.java +++ b/junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/discovery/MethodOrderingVisitor.java @@ -10,12 +10,14 @@ package org.junit.jupiter.engine.discovery; +import static java.util.Comparator.comparing; import static org.junit.platform.commons.support.AnnotationSupport.findAnnotation; import static org.junit.platform.commons.support.AnnotationSupport.isAnnotated; import java.util.List; import java.util.Optional; import java.util.function.Consumer; +import java.util.function.UnaryOperator; import org.junit.jupiter.api.MethodOrderer; import org.junit.jupiter.api.Order; @@ -40,6 +42,9 @@ class MethodOrderingVisitor extends AbstractOrderingVisitor { private final JupiterConfiguration configuration; private final Condition noOrderAnnotation; + // Not a static field to avoid initialization at build time for GraalVM + private final UnaryOperator> methodsBeforeNestedClassesOrderer; + MethodOrderingVisitor(JupiterConfiguration configuration, DiscoveryIssueReporter issueReporter) { super(issueReporter); this.configuration = configuration; @@ -52,6 +57,7 @@ class MethodOrderingVisitor extends AbstractOrderingVisitor { .source(MethodSource.from(testDescriptor.getTestMethod())) // .build(); }); + this.methodsBeforeNestedClassesOrderer = createMethodsBeforeNestedClassesOrderer(); } @Override @@ -82,6 +88,7 @@ private void orderContainedMethods(ClassBasedTestDescriptor classBasedTestDescri private void orderContainedMethods(ClassBasedTestDescriptor classBasedTestDescriptor, Class testClass, Optional methodOrderer) { + DescriptorWrapperOrderer descriptorWrapperOrderer = createDescriptorWrapperOrderer( testClass, methodOrderer); @@ -91,6 +98,11 @@ private void orderContainedMethods(ClassBasedTestDescriptor classBasedTestDescri DefaultMethodDescriptor::new, // descriptorWrapperOrderer); + if (methodOrderer.isEmpty()) { + // If there is an orderer, this is ensured by the call above + classBasedTestDescriptor.orderChildren(methodsBeforeNestedClassesOrderer); + } + // Note: MethodOrderer#getDefaultExecutionMode() is guaranteed // to be invoked after MethodOrderer#orderMethods(). methodOrderer // @@ -130,4 +142,12 @@ private Optional> toValidationAction(Optiona return Optional.of(noOrderAnnotation::check); } + private static UnaryOperator> createMethodsBeforeNestedClassesOrderer() { + var methodsFirst = comparing(MethodBasedTestDescriptor.class::isInstance).reversed(); + return children -> { + children.sort(methodsFirst); + return children; + }; + } + } diff --git a/jupiter-tests/src/test/java/org/junit/jupiter/engine/NestedTestClassesTests.java b/jupiter-tests/src/test/java/org/junit/jupiter/engine/NestedTestClassesTests.java index 2fe8352f41b8..ca36a15b1183 100644 --- a/jupiter-tests/src/test/java/org/junit/jupiter/engine/NestedTestClassesTests.java +++ b/jupiter-tests/src/test/java/org/junit/jupiter/engine/NestedTestClassesTests.java @@ -13,8 +13,10 @@ import static org.assertj.core.api.Assertions.assertThat; import static org.junit.jupiter.api.Assertions.assertAll; import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.platform.engine.discovery.ClassNameFilter.includeClassNamePatterns; import static org.junit.platform.engine.discovery.DiscoverySelectors.selectClass; import static org.junit.platform.engine.discovery.DiscoverySelectors.selectMethod; +import static org.junit.platform.engine.discovery.DiscoverySelectors.selectPackage; import static org.junit.platform.engine.discovery.DiscoverySelectors.selectUniqueId; import static org.junit.platform.launcher.LauncherConstants.CRITICAL_DISCOVERY_ISSUE_SEVERITY_PROPERTY_NAME; import static org.junit.platform.launcher.core.LauncherDiscoveryRequestBuilder.request; @@ -22,19 +24,25 @@ import static org.junit.platform.testkit.engine.TestExecutionResultConditions.message; import java.util.List; +import java.util.function.Consumer; +import java.util.regex.Pattern; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Named; import org.junit.jupiter.api.Nested; import org.junit.jupiter.api.Test; import org.junit.jupiter.engine.NestedTestClassesTests.OuterClass.NestedClass; import org.junit.jupiter.engine.NestedTestClassesTests.OuterClass.NestedClass.RecursiveNestedClass; import org.junit.jupiter.engine.NestedTestClassesTests.OuterClass.NestedClass.RecursiveNestedSiblingClass; +import org.junit.jupiter.params.ParameterizedTest; +import org.junit.jupiter.params.provider.MethodSource; import org.junit.platform.engine.DiscoveryIssue.Severity; import org.junit.platform.engine.TestDescriptor; import org.junit.platform.engine.support.descriptor.ClassSource; import org.junit.platform.launcher.LauncherDiscoveryRequest; +import org.junit.platform.launcher.core.LauncherDiscoveryRequestBuilder; import org.junit.platform.testkit.engine.EngineExecutionResults; import org.junit.platform.testkit.engine.Events; @@ -53,20 +61,36 @@ void nestedTestsAreCorrectlyDiscovered() { assertEquals(5, engineDescriptor.getDescendants().size(), "# resolved test descriptors"); } - @Test - void nestedTestsAreExecuted() { - EngineExecutionResults executionResults = executeTestsForClass(TestCaseWithNesting.class); - Events containers = executionResults.containerEvents(); - Events tests = executionResults.testEvents(); + @ParameterizedTest(name = "{0}") + @MethodSource + void nestedTestsAreExecutedInTheRightOrder(Consumer configurer) { + EngineExecutionResults executionResults = executeTests(configurer); + Events tests = executionResults.testEvents(); assertEquals(3, tests.started().count(), "# tests started"); assertEquals(2, tests.succeeded().count(), "# tests succeeded"); assertEquals(1, tests.failed().count(), "# tests failed"); + assertThat(tests.started().map(it -> it.getTestDescriptor().getDisplayName())) // + .containsExactlyInAnyOrder("someTest()", "successful()", "failing()") // + .containsSubsequence("someTest()", "successful()") // + .containsSubsequence("someTest()", "failing()"); + + Events containers = executionResults.containerEvents(); assertEquals(3, containers.started().count(), "# containers started"); assertEquals(3, containers.finished().count(), "# containers finished"); } + static List>> nestedTestsAreExecutedInTheRightOrder() { + return List.of( // + Named.of("class selector", request -> request // + .selectors(selectClass(TestCaseWithNesting.class))), + Named.of("package selector", request -> request // + .selectors(selectPackage(TestCaseWithNesting.class.getPackageName())) // + .filters(includeClassNamePatterns(Pattern.quote(TestCaseWithNesting.class.getName()) + ".*"))) // + ); + } + @Test void doublyNestedTestsAreCorrectlyDiscovered() { LauncherDiscoveryRequest request = request().selectors(selectClass(TestCaseWithDoubleNesting.class)).build(); From 4170597350f414cc9e42cfc46e8dffaa93cb73cb Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Wed, 4 Jun 2025 12:06:30 +0200 Subject: [PATCH 026/109] Restore compatibility with Java 8 --- .../jupiter/engine/discovery/MethodOrderingVisitor.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/discovery/MethodOrderingVisitor.java b/junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/discovery/MethodOrderingVisitor.java index 48a3d4c8228f..d1aeb152cc30 100644 --- a/junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/discovery/MethodOrderingVisitor.java +++ b/junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/discovery/MethodOrderingVisitor.java @@ -14,6 +14,7 @@ import static org.junit.platform.commons.support.AnnotationSupport.findAnnotation; import static org.junit.platform.commons.support.AnnotationSupport.isAnnotated; +import java.util.Comparator; import java.util.List; import java.util.Optional; import java.util.function.Consumer; @@ -98,7 +99,7 @@ private void orderContainedMethods(ClassBasedTestDescriptor classBasedTestDescri DefaultMethodDescriptor::new, // descriptorWrapperOrderer); - if (methodOrderer.isEmpty()) { + if (!methodOrderer.isPresent()) { // If there is an orderer, this is ensured by the call above classBasedTestDescriptor.orderChildren(methodsBeforeNestedClassesOrderer); } @@ -143,7 +144,7 @@ private Optional> toValidationAction(Optiona } private static UnaryOperator> createMethodsBeforeNestedClassesOrderer() { - var methodsFirst = comparing(MethodBasedTestDescriptor.class::isInstance).reversed(); + Comparator methodsFirst = comparing(MethodBasedTestDescriptor.class::isInstance).reversed(); return children -> { children.sort(methodsFirst); return children; From af5e3bd975addecea38e831babb8187d3daa65c9 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Fri, 6 Jun 2025 18:34:43 +0200 Subject: [PATCH 027/109] Fix support pre-5.13 `AnnotationBasedArgumentsProvider` implementations (#4611) The `provideArguments(ExtensionContext, Annotation)` was deprecated in 5.13 and no longer taken into account when determining the consumed annotation. Now, it is checked for again if the new method overload couldn't be found. Fixes #4610. (cherry picked from commit 4bbe57dfbf18efcc3f84111baf2458198ff26c04) --- .../release-notes/release-notes-5.13.1.adoc | 2 + .../AnnotationConsumerInitializer.java | 1 + .../AnnotationConsumerInitializerTests.java | 41 +++++++++++++++---- 3 files changed, 37 insertions(+), 7 deletions(-) diff --git a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc index 505bdb10b39b..388e5a1dde1c 100644 --- a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc +++ b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc @@ -42,6 +42,8 @@ on GitHub. in their enclosing class. This undesired change in behavior has now been reverted so that tests in `@Nested` test classes are always executed _after_ tests in enclosing test classes again. +* Fix support for `AnnotationBasedArgumentsProvider` implementations that override the + deprecated `provideArguments(ExtensionContext, Annotation)` method. [[release-notes-5.13.1-junit-jupiter-deprecations-and-breaking-changes]] ==== Deprecations and Breaking Changes diff --git a/junit-jupiter-params/src/main/java/org/junit/jupiter/params/support/AnnotationConsumerInitializer.java b/junit-jupiter-params/src/main/java/org/junit/jupiter/params/support/AnnotationConsumerInitializer.java index 785c9e571fc4..c05c323b4fbc 100644 --- a/junit-jupiter-params/src/main/java/org/junit/jupiter/params/support/AnnotationConsumerInitializer.java +++ b/junit-jupiter-params/src/main/java/org/junit/jupiter/params/support/AnnotationConsumerInitializer.java @@ -41,6 +41,7 @@ public final class AnnotationConsumerInitializer { private static final List annotationConsumingMethodSignatures = asList( // new AnnotationConsumingMethodSignature("accept", 1, 0), // new AnnotationConsumingMethodSignature("provideArguments", 3, 2), // + new AnnotationConsumingMethodSignature("provideArguments", 2, 1), // new AnnotationConsumingMethodSignature("convert", 3, 2)); private AnnotationConsumerInitializer() { diff --git a/jupiter-tests/src/test/java/org/junit/jupiter/params/support/AnnotationConsumerInitializerTests.java b/jupiter-tests/src/test/java/org/junit/jupiter/params/support/AnnotationConsumerInitializerTests.java index 16306451bca4..0e14dd36283a 100644 --- a/jupiter-tests/src/test/java/org/junit/jupiter/params/support/AnnotationConsumerInitializerTests.java +++ b/jupiter-tests/src/test/java/org/junit/jupiter/params/support/AnnotationConsumerInitializerTests.java @@ -23,17 +23,21 @@ import java.time.LocalDate; import java.util.ArrayList; import java.util.List; +import java.util.function.Supplier; import java.util.stream.Stream; import org.junit.jupiter.api.DisplayName; +import org.junit.jupiter.api.Named; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.extension.ExtensionContext; import org.junit.jupiter.api.extension.ParameterContext; +import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.converter.AnnotationBasedArgumentConverter; import org.junit.jupiter.params.converter.JavaTimeConversionPattern; import org.junit.jupiter.params.provider.AnnotationBasedArgumentsProvider; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.CsvSource; +import org.junit.jupiter.params.provider.FieldSource; import org.junit.platform.commons.JUnitException; @DisplayName("AnnotationConsumerInitializer") @@ -51,10 +55,11 @@ void shouldInitializeAnnotationConsumer() throws NoSuchMethodException { source -> assertThat(source.value()).containsExactly("a", "b")); } - @Test + @ParameterizedTest + @FieldSource("argumentsProviders") @DisplayName("should initialize annotation-based ArgumentsProvider") - void shouldInitializeAnnotationBasedArgumentsProvider() throws NoSuchMethodException { - var instance = new SomeAnnotationBasedArgumentsProvider(); + void shouldInitializeAnnotationBasedArgumentsProvider(AbstractAnnotationBasedArgumentsProvider instance) + throws NoSuchMethodException { var method = SubjectClass.class.getDeclaredMethod("foo"); var initialisedAnnotationConsumer = initialize(method, instance); @@ -101,9 +106,11 @@ void shouldThrowExceptionWhenParameterIsNotAnnotated() throws NoSuchMethodExcept assertThatThrownBy(() -> initialize(parameter, instance)).isInstanceOf(JUnitException.class); } - @Test - void shouldInitializeForEachAnnotations() throws NoSuchMethodException { - var instance = spy(new SomeAnnotationBasedArgumentsProvider()); + @ParameterizedTest + @FieldSource("argumentsProviders") + void shouldInitializeForEachAnnotations(AbstractAnnotationBasedArgumentsProvider provider) + throws NoSuchMethodException { + var instance = spy(provider); var method = SubjectClass.class.getDeclaredMethod("repeatableAnnotation", String.class); initialize(method, instance); @@ -111,10 +118,20 @@ void shouldInitializeForEachAnnotations() throws NoSuchMethodException { verify(instance, times(2)).accept(any(CsvSource.class)); } - private static class SomeAnnotationBasedArgumentsProvider extends AnnotationBasedArgumentsProvider { + static Supplier>> argumentsProviders = () -> List.of( // + Named.of("current", new SomeAnnotationBasedArgumentsProvider()), // + Named.of("deprecated", new DeprecatedAnnotationBasedArgumentsProvider()) // + ); + + private static abstract class AbstractAnnotationBasedArgumentsProvider + extends AnnotationBasedArgumentsProvider { List annotations = new ArrayList<>(); + } + + private static class SomeAnnotationBasedArgumentsProvider extends AbstractAnnotationBasedArgumentsProvider { + @Override protected Stream provideArguments(ParameterDeclarations parameters, ExtensionContext context, CsvSource annotation) { @@ -123,6 +140,16 @@ protected Stream provideArguments(ParameterDeclarations par } } + private static class DeprecatedAnnotationBasedArgumentsProvider extends AbstractAnnotationBasedArgumentsProvider { + + @Override + @SuppressWarnings("deprecation") + protected Stream provideArguments(ExtensionContext context, CsvSource annotation) { + annotations.add(annotation); + return Stream.empty(); + } + } + private static class SomeAnnotationBasedArgumentConverter extends AnnotationBasedArgumentConverter { From f0747f192d05dc9688b31eb6a4739e8a5164118d Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Fri, 30 May 2025 14:08:19 +0200 Subject: [PATCH 028/109] Use GraphQL API to list matching milestones to avoid pagination issues (cherry picked from commit 5631ae577deb826ba2a5f8d3e1a7f6b8b68d379e) --- .github/workflows/release.yml | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d1a91be83ec8..0ba681c68077 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -119,17 +119,30 @@ jobs: with: result-encoding: string script: | - const openMilestones = await github.rest.issues.listMilestones({ + const query = ` + query ($owner: String!, $repo: String!, $title: String!) { + repository(owner: $owner, name: $repo) { + milestones(first: 100, query: $title) { + nodes { + title + number + openIssueCount + } + } + } + } + `; + const {repository} = await github.graphql(query, { owner: context.repo.owner, repo: context.repo.repo, - state: 'open' + title: "${{ inputs.releaseVersion }}" }); - const [milestone] = openMilestones.data.filter(x => x.title === "${{ inputs.releaseVersion }}") + const [milestone] = repository.milestones.nodes.filter(it => it.title === "${{ inputs.releaseVersion }}") if (!milestone) { throw new Error('Milestone "${{ inputs.releaseVersion }}" not found'); } - if (milestone.open_issues > 0) { - throw new Error(`Milestone "${{ inputs.releaseVersion }}" has ${milestone.open_issues} open issue(s)`); + if (milestone.openIssueCount > 0) { + throw new Error(`Milestone "${{ inputs.releaseVersion }}" has ${milestone.openIssueCount} open issue(s)`); } const requestBody = { owner: context.repo.owner, From 97095e92bea117e52551066bd91d7b155b9d9aa5 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Sat, 7 Jun 2025 09:29:55 +0200 Subject: [PATCH 029/109] Finalize 5.13.1 release notes (cherry picked from commit bd496b0ef24f196b69d85fcbacc7a36205341995) --- .../release-notes/release-notes-5.13.1.adoc | 44 ++----------------- 1 file changed, 4 insertions(+), 40 deletions(-) diff --git a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc index 388e5a1dde1c..cfd56ea3e397 100644 --- a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc +++ b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.1.adoc @@ -1,9 +1,9 @@ [[release-notes-5.13.1]] == 5.13.1 -*Date of Release:* ❓ +*Date of Release:* June 7, 2025 -*Scope:* ❓ +*Scope:* Bug fixes and enhancements since 5.13.0 For a complete list of all _closed_ issues and pull requests for this release, consult the link:{junit5-repo}+/milestone/97?closed=1+[5.13.1] milestone page in the JUnit repository @@ -13,20 +13,7 @@ on GitHub. [[release-notes-5.13.1-junit-platform]] === JUnit Platform -[[release-notes-5.13.1-junit-platform-bug-fixes]] -==== Bug Fixes - -* ❓ - -[[release-notes-5.13.1-junit-platform-deprecations-and-breaking-changes]] -==== Deprecations and Breaking Changes - -* ❓ - -[[release-notes-5.13.1-junit-platform-new-features-and-improvements]] -==== New Features and Improvements - -* ❓ +No changes. [[release-notes-5.13.1-junit-jupiter]] @@ -45,31 +32,8 @@ on GitHub. * Fix support for `AnnotationBasedArgumentsProvider` implementations that override the deprecated `provideArguments(ExtensionContext, Annotation)` method. -[[release-notes-5.13.1-junit-jupiter-deprecations-and-breaking-changes]] -==== Deprecations and Breaking Changes - -* ❓ - -[[release-notes-5.13.1-junit-jupiter-new-features-and-improvements]] -==== New Features and Improvements - -* ❓ - [[release-notes-5.13.1-junit-vintage]] === JUnit Vintage -[[release-notes-5.13.1-junit-vintage-bug-fixes]] -==== Bug Fixes - -* ❓ - -[[release-notes-5.13.1-junit-vintage-deprecations-and-breaking-changes]] -==== Deprecations and Breaking Changes - -* ❓ - -[[release-notes-5.13.1-junit-vintage-new-features-and-improvements]] -==== New Features and Improvements - -* ❓ +No changes From b580aa90923f44aaa412ae32ba0915b06f96c697 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Sat, 7 Jun 2025 09:48:42 +0200 Subject: [PATCH 030/109] Release 5.13.1 --- README.md | 2 +- gradle.properties | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 4f6249075d16..c1a30d55b379 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ This repository is the home of _JUnit 5_. ## Latest Releases -- General Availability (GA): [JUnit 5.13.0](https://github.com/junit-team/junit5/releases/tag/r5.13.0) (May 30, 2025) +- General Availability (GA): [JUnit 5.13.1](https://github.com/junit-team/junit5/releases/tag/r5.13.1) (June 7, 2025) - Preview (Milestone/Release Candidate): [JUnit 5.13.0-RC1](https://github.com/junit-team/junit5/releases/tag/r5.13.0-RC1) (May 16, 2025) ## Documentation diff --git a/gradle.properties b/gradle.properties index 235ab09ed115..0e69e1385cc5 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,13 +1,13 @@ group = org.junit -version = 5.13.1-SNAPSHOT +version = 5.13.1 jupiterGroup = org.junit.jupiter platformGroup = org.junit.platform -platformVersion = 1.13.1-SNAPSHOT +platformVersion = 1.13.1 vintageGroup = org.junit.vintage -vintageVersion = 5.13.1-SNAPSHOT +vintageVersion = 5.13.1 # We need more metaspace due to apparent memory leak in Asciidoctor/JRuby org.gradle.jvmargs=-Xmx1g -XX:MaxMetaspaceSize=512m -XX:+HeapDumpOnOutOfMemoryError From 5ca9829468e57fb79dcebd0535bca63a00486eaf Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Sat, 7 Jun 2025 09:52:28 +0200 Subject: [PATCH 031/109] Back to snapshots for further development --- gradle.properties | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gradle.properties b/gradle.properties index 0e69e1385cc5..f2b2b5951f16 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,13 +1,13 @@ group = org.junit -version = 5.13.1 +version = 5.13.2-SNAPSHOT jupiterGroup = org.junit.jupiter platformGroup = org.junit.platform -platformVersion = 1.13.1 +platformVersion = 1.13.2-SNAPSHOT vintageGroup = org.junit.vintage -vintageVersion = 5.13.1 +vintageVersion = 5.13.2-SNAPSHOT # We need more metaspace due to apparent memory leak in Asciidoctor/JRuby org.gradle.jvmargs=-Xmx1g -XX:MaxMetaspaceSize=512m -XX:+HeapDumpOnOutOfMemoryError From 44607f0f4a776d6a7ac67199d61f7896b39c8cbc Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Wed, 18 Jun 2025 17:23:43 +0200 Subject: [PATCH 032/109] Add reference to `@ParameterizedClass` (cherry picked from commit 2ab952c7e9c73f685b849b836a5ccf13761ae1bb) --- .../junit/jupiter/params/converter/ArgumentConverter.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/junit-jupiter-params/src/main/java/org/junit/jupiter/params/converter/ArgumentConverter.java b/junit-jupiter-params/src/main/java/org/junit/jupiter/params/converter/ArgumentConverter.java index eae935d66e75..85a8e222b42c 100644 --- a/junit-jupiter-params/src/main/java/org/junit/jupiter/params/converter/ArgumentConverter.java +++ b/junit-jupiter-params/src/main/java/org/junit/jupiter/params/converter/ArgumentConverter.java @@ -25,8 +25,12 @@ * *

Such an {@code ArgumentConverter} is applied to the method parameter * of a {@link org.junit.jupiter.params.ParameterizedTest @ParameterizedTest} - * method with the help of a - * {@link org.junit.jupiter.params.converter.ConvertWith @ConvertWith} annotation. + * or a constructor parameter or + * {@link org.junit.jupiter.params.Parameter @Parameter}-annotated field of a + * {@link org.junit.jupiter.params.ParameterizedClass @ParameterizedClass} with + * the help of a + * {@link org.junit.jupiter.params.converter.ConvertWith @ConvertWith} + * annotation. * *

Implementations must provide a no-args constructor or a single unambiguous * constructor to use {@linkplain ParameterResolver parameter resolution}. They From ae1780fb43372202464671fd4e4615e9a7d23db2 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Wed, 18 Jun 2025 17:24:38 +0200 Subject: [PATCH 033/109] Use automatic token for publication to GitHub Pages (cherry picked from commit c662e7997a46be6a320ec0bc1904211b2150f907) --- .github/workflows/main.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index aadc10b78069..ddb24f613c26 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -104,6 +104,8 @@ jobs: cancel-in-progress: true needs: macOS runs-on: ubuntu-latest + permissions: + contents: write steps: - name: Check out repository uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 @@ -135,4 +137,4 @@ jobs: -Dscan.tag.Documentation env: GIT_USERNAME: git - GIT_PASSWORD: ${{ secrets.GH_TOKEN }} + GIT_PASSWORD: ${{ secrets.GITHUB_TOKEN }} From e4363d11dcdc6aacc5d8c60f8cf5781e973b4e28 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Wed, 18 Jun 2025 18:01:49 +0200 Subject: [PATCH 034/109] Stop trying to write to remote build cache PR builds from forks (cherry picked from commit fff3323dbd58c80f7340c90fbde2a7d87349eea0) --- settings.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/settings.gradle.kts b/settings.gradle.kts index ba5ae9fd677f..0add77681497 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -57,7 +57,7 @@ buildCache { if (useDevelocityInstance) { remote(develocity.buildCache) { server = buildCacheServer.orNull - val authenticated = System.getenv("DEVELOCITY_ACCESS_KEY") != null + val authenticated = System.getenv("DEVELOCITY_ACCESS_KEY").isNotBlank() isPush = buildParameters.ci && authenticated } } else { From ea8367db13e1e63b5f784be0d1125fbe14c0313a Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Wed, 18 Jun 2025 19:29:29 +0200 Subject: [PATCH 035/109] Avoid failing of `DEVELOCITY_ACCESS_KEY` env var is not set (cherry picked from commit 57e3991c54742f3ffd2cc89b19ccfecc40891256) --- settings.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/settings.gradle.kts b/settings.gradle.kts index 0add77681497..1ec855e53437 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -57,7 +57,7 @@ buildCache { if (useDevelocityInstance) { remote(develocity.buildCache) { server = buildCacheServer.orNull - val authenticated = System.getenv("DEVELOCITY_ACCESS_KEY").isNotBlank() + val authenticated = !System.getenv("DEVELOCITY_ACCESS_KEY").isNullOrEmpty() isPush = buildParameters.ci && authenticated } } else { From e51d27b32991ebdb76650a2b91330f8d7a681dcb Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Wed, 18 Jun 2025 19:30:24 +0200 Subject: [PATCH 036/109] Inject `DEVELOCITY_ACCESS_KEY` to dependency graph workflow (cherry picked from commit 1e4b681522972966f0d9d628293dbb8861f10f7f) --- .github/workflows/gradle-dependency-submission.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/gradle-dependency-submission.yml b/.github/workflows/gradle-dependency-submission.yml index eda44140d013..81eaddcd051d 100644 --- a/.github/workflows/gradle-dependency-submission.yml +++ b/.github/workflows/gradle-dependency-submission.yml @@ -7,6 +7,9 @@ on: permissions: read-all +env: + DEVELOCITY_ACCESS_KEY: ${{ secrets.DEVELOCITY_ACCESS_KEY }} + jobs: dependency-submission: if: github.repository == 'junit-team/junit5' From 35e870136fe42d19b6d93c89d16d9bdeb6db0ffb Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Thu, 19 Jun 2025 07:57:36 +0200 Subject: [PATCH 037/109] Use automatic token for publication to GitHub Pages for releases (cherry picked from commit 5fc82070a3c398cef0199c4c3c23fd21590e93d5) --- .github/workflows/release.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0ba681c68077..dcfd24e30c25 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -180,6 +180,8 @@ jobs: name: Publish documentation needs: publish_deployment runs-on: ubuntu-latest + permissions: + contents: write steps: - name: Check out repository uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 @@ -209,7 +211,7 @@ jobs: uses: ./.github/actions/run-gradle env: GIT_USERNAME: git - GIT_PASSWORD: ${{ secrets.GH_TOKEN }} + GIT_PASSWORD: ${{ secrets.GITHUB_TOKEN }} with: encryptionKey: ${{ secrets.GRADLE_ENCRYPTION_KEY }} arguments: | From e07c58815dca84035e477ebdfd9d151fbb04bb9d Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Thu, 19 Jun 2025 08:04:28 +0200 Subject: [PATCH 038/109] Use fine-grained access token to read/write samples repo during release (cherry picked from commit 5804bf244d7df8244d031accadc2dcb3baf05fd1) --- .github/workflows/release.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index dcfd24e30c25..eb4ef1585634 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -81,7 +81,7 @@ jobs: uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: repository: ${{ github.repository_owner }}/junit5-samples - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.JUNIT_BUILDS_GITHUB_TOKEN_SAMPLES_REPO }} fetch-depth: 1 path: junit5-samples - name: Set up JDK @@ -242,7 +242,7 @@ jobs: uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: repository: ${{ github.repository_owner }}/junit5-samples - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.JUNIT_BUILDS_GITHUB_TOKEN_SAMPLES_REPO }} fetch-depth: 1 - name: Set up JDK uses: actions/setup-java@c5195efecf7bdfc987ee8bae7a71cb8b11521c00 # v4.7.1 From 623191cad6e39217c49529d629b21c8420a8bc02 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Thu, 19 Jun 2025 08:11:18 +0200 Subject: [PATCH 039/109] Stop passing `GITHUB_TOKEN` explicitly as it's the default (cherry picked from commit f4ff00db6b6d99cbaf377d2fc90f2463d1edd8c2) --- .github/workflows/main.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index ddb24f613c26..4955603a695c 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -30,7 +30,6 @@ jobs: distribution: graalvm-community version: 'latest' java-version: '21' - github-token: ${{ secrets.GITHUB_TOKEN }} - name: Build uses: ./.github/actions/main-build with: From ec3881c5d3ffeacee499a75c31a114fb7daa4c69 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Fri, 20 Jun 2025 14:40:19 +0200 Subject: [PATCH 040/109] Publish documentation to docs.junit.org GitHub repo's main branch (cherry picked from commit a5e8eb39dbe3931ce9e8232c95e686d9619ce1cf) --- .github/workflows/main.yml | 4 +--- .github/workflows/release.yml | 4 +--- documentation/documentation.gradle.kts | 11 +++++------ 3 files changed, 7 insertions(+), 12 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 4955603a695c..b521978bdf43 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -103,8 +103,6 @@ jobs: cancel-in-progress: true needs: macOS runs-on: ubuntu-latest - permissions: - contents: write steps: - name: Check out repository uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 @@ -136,4 +134,4 @@ jobs: -Dscan.tag.Documentation env: GIT_USERNAME: git - GIT_PASSWORD: ${{ secrets.GITHUB_TOKEN }} + GIT_PASSWORD: ${{ secrets.JUNIT_BUILDS_GITHUB_TOKEN_DOCS_REPO }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index eb4ef1585634..fa12d9c03639 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -180,8 +180,6 @@ jobs: name: Publish documentation needs: publish_deployment runs-on: ubuntu-latest - permissions: - contents: write steps: - name: Check out repository uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 @@ -211,7 +209,7 @@ jobs: uses: ./.github/actions/run-gradle env: GIT_USERNAME: git - GIT_PASSWORD: ${{ secrets.GITHUB_TOKEN }} + GIT_PASSWORD: ${{ secrets.JUNIT_BUILDS_GITHUB_TOKEN_DOCS_REPO }} with: encryptionKey: ${{ secrets.GRADLE_ENCRYPTION_KEY }} arguments: | diff --git a/documentation/documentation.gradle.kts b/documentation/documentation.gradle.kts index a5f806e99b60..ae3f203f3911 100644 --- a/documentation/documentation.gradle.kts +++ b/documentation/documentation.gradle.kts @@ -108,10 +108,9 @@ val ota4jDocVersion = libs.versions.opentest4j.map { if (it.isSnapshot()) "snaps val apiGuardianDocVersion = libs.versions.apiguardian.map { if (it.isSnapshot()) "snapshot" else it }.get() gitPublish { - repoUri = "https://github.com/junit-team/junit5.git" - referenceRepoUri = rootDir.toURI().toString() + repoUri = "https://github.com/junit-team/docs.junit.org.git" - branch = "gh-pages" + branch = "main" sign = false fetchDepth = 1 @@ -120,14 +119,14 @@ gitPublish { contents { from(docsDir) - into("docs") + into(".") } preserve { include("**/*") - exclude("docs/$docsVersion/**") + exclude("$docsVersion/**") if (replaceCurrentDocs) { - exclude("docs/current/**") + exclude("current/**") } } } From 0009e686250eea739828e8e7a03e17f5477e9936 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Tue, 17 Jun 2025 09:49:41 +0200 Subject: [PATCH 041/109] Create initial 5.13.2 release notes from template (cherry picked from commit e6ab3e35ff8df6f433c1eea0b13010ceebfffe03) --- .../docs/asciidoc/release-notes/index.adoc | 2 + .../release-notes/release-notes-5.13.2.adoc | 67 +++++++++++++++++++ 2 files changed, 69 insertions(+) create mode 100644 documentation/src/docs/asciidoc/release-notes/release-notes-5.13.2.adoc diff --git a/documentation/src/docs/asciidoc/release-notes/index.adoc b/documentation/src/docs/asciidoc/release-notes/index.adoc index 62d53b05257e..6bb9b4c46d3d 100644 --- a/documentation/src/docs/asciidoc/release-notes/index.adoc +++ b/documentation/src/docs/asciidoc/release-notes/index.adoc @@ -17,6 +17,8 @@ authors as well as build tool and IDE vendors. include::{includedir}/link-attributes.adoc[] +include::{basedir}/release-notes-5.13.2.adoc[] + include::{basedir}/release-notes-5.13.1.adoc[] include::{basedir}/release-notes-5.13.0.adoc[] diff --git a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.2.adoc b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.2.adoc new file mode 100644 index 000000000000..633f4b185eac --- /dev/null +++ b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.2.adoc @@ -0,0 +1,67 @@ +[[release-notes-5.13.2]] +== 5.13.2 + +*Date of Release:* ❓ + +*Scope:* ❓ + +For a complete list of all _closed_ issues and pull requests for this release, consult the +link:{junit5-repo}+/milestone/98?closed=1+[5.13.2] milestone page in the JUnit repository +on GitHub. + + +[[release-notes-5.13.2-junit-platform]] +=== JUnit Platform + +[[release-notes-5.13.2-junit-platform-bug-fixes]] +==== Bug Fixes + +* ❓ + +[[release-notes-5.13.2-junit-platform-deprecations-and-breaking-changes]] +==== Deprecations and Breaking Changes + +* ❓ + +[[release-notes-5.13.2-junit-platform-new-features-and-improvements]] +==== New Features and Improvements + +* ❓ + + +[[release-notes-5.13.2-junit-jupiter]] +=== JUnit Jupiter + +[[release-notes-5.13.2-junit-jupiter-bug-fixes]] +==== Bug Fixes + +* ❓ + +[[release-notes-5.13.2-junit-jupiter-deprecations-and-breaking-changes]] +==== Deprecations and Breaking Changes + +* ❓ + +[[release-notes-5.13.2-junit-jupiter-new-features-and-improvements]] +==== New Features and Improvements + +* ❓ + + +[[release-notes-5.13.2-junit-vintage]] +=== JUnit Vintage + +[[release-notes-5.13.2-junit-vintage-bug-fixes]] +==== Bug Fixes + +* ❓ + +[[release-notes-5.13.2-junit-vintage-deprecations-and-breaking-changes]] +==== Deprecations and Breaking Changes + +* ❓ + +[[release-notes-5.13.2-junit-vintage-new-features-and-improvements]] +==== New Features and Improvements + +* ❓ From 6b256d603005f8cd06a5ca5f143afaee3792608e Mon Sep 17 00:00:00 2001 From: Christian Stein Date: Tue, 17 Jun 2025 11:58:26 +0200 Subject: [PATCH 042/109] Add `JAVA_26` to `JRE` enum Add `JRE.JAVA_26` constant and introduce JDK 26-ea CI build Closes #4642 (cherry picked from commit 00d380bfce0902e5231afaed2dcf84e8dd861c20) --- .github/workflows/cross-version.yml | 2 ++ .../base/code-generator-model/src/main/resources/jre.yaml | 2 ++ .../api/condition/EnabledForJreRangeConditionTests.java | 6 ++++-- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.github/workflows/cross-version.yml b/.github/workflows/cross-version.yml index 7c51412feaaf..f4d5049f0324 100644 --- a/.github/workflows/cross-version.yml +++ b/.github/workflows/cross-version.yml @@ -26,6 +26,8 @@ jobs: type: ga - version: 25 type: ea + - version: 26 + type: ea name: "OpenJDK ${{ matrix.jdk.version }} (${{ matrix.jdk.release || matrix.jdk.type }})" runs-on: ubuntu-latest steps: diff --git a/gradle/base/code-generator-model/src/main/resources/jre.yaml b/gradle/base/code-generator-model/src/main/resources/jre.yaml index 1747ffa12dd6..90654b64919d 100644 --- a/gradle/base/code-generator-model/src/main/resources/jre.yaml +++ b/gradle/base/code-generator-model/src/main/resources/jre.yaml @@ -30,3 +30,5 @@ since: '5.11' - version: 25 since: '5.11.4' +- version: 26 + since: '6.0' diff --git a/jupiter-tests/src/test/java/org/junit/jupiter/api/condition/EnabledForJreRangeConditionTests.java b/jupiter-tests/src/test/java/org/junit/jupiter/api/condition/EnabledForJreRangeConditionTests.java index 886af0b8e309..21b3eac63172 100644 --- a/jupiter-tests/src/test/java/org/junit/jupiter/api/condition/EnabledForJreRangeConditionTests.java +++ b/jupiter-tests/src/test/java/org/junit/jupiter/api/condition/EnabledForJreRangeConditionTests.java @@ -27,6 +27,7 @@ import static org.junit.jupiter.api.condition.JavaVersionPredicates.onJava23; import static org.junit.jupiter.api.condition.JavaVersionPredicates.onJava24; import static org.junit.jupiter.api.condition.JavaVersionPredicates.onJava25; +import static org.junit.jupiter.api.condition.JavaVersionPredicates.onJava26; import static org.junit.jupiter.api.condition.JavaVersionPredicates.onJava8; import static org.junit.jupiter.api.condition.JavaVersionPredicates.onJava9; import static org.junit.jupiter.api.condition.JavaVersionPredicates.onKnownVersion; @@ -209,7 +210,8 @@ void minVersionGreaterThanMax() { @Test void min20() { evaluateCondition(); - assertEnabledOnCurrentJreIf(onJava20() || onJava21() || onJava22() || onJava23() || onJava24() || onJava25()); + assertEnabledOnCurrentJreIf( + onJava20() || onJava21() || onJava22() || onJava23() || onJava24() || onJava25() || onJava26()); } /** @@ -320,7 +322,7 @@ void minVersion20MaxVersion21() { void minVersion17MaxVersionMaxInteger() { evaluateCondition(); assertEnabledOnCurrentJreIf(onJava17() || onJava18() || onJava19() || onJava20() || onJava21() || onJava22() - || onJava23() || onJava24() || onJava25()); + || onJava23() || onJava24() || onJava25() || onJava26()); } /** From 70811992fded377d7add9d228178a57533d6d3d9 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Sat, 21 Jun 2025 13:23:38 +0200 Subject: [PATCH 043/109] Move entry to 5.13.2 release notes (cherry picked from commit 801d5461a8ecbf0032d840c5e14b57a66bd04177) --- .../src/docs/asciidoc/release-notes/release-notes-5.13.2.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.2.adoc b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.2.adoc index 633f4b185eac..667da2449d27 100644 --- a/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.2.adoc +++ b/documentation/src/docs/asciidoc/release-notes/release-notes-5.13.2.adoc @@ -45,7 +45,7 @@ on GitHub. [[release-notes-5.13.2-junit-jupiter-new-features-and-improvements]] ==== New Features and Improvements -* ❓ +* `JAVA_26` has been added to the `JRE` enum for use with JRE-based execution conditions. [[release-notes-5.13.2-junit-vintage]] From 88281f391bdc1ef9e3d896ca3234623c809fc1d5 Mon Sep 17 00:00:00 2001 From: Christian Stein Date: Mon, 26 May 2025 18:18:51 +0200 Subject: [PATCH 044/109] Update links to Maven Central and GitHub Discussions Co-authored-by: Marc Philipp (cherry picked from commit 3d74a06879fd97ab91f287c74f8e4ea21e36a9ca) --- README.md | 15 +++++---------- .../src/docs/asciidoc/link-attributes.adoc | 4 ++-- .../src/docs/asciidoc/user-guide/appendix.adoc | 11 ++++++++--- .../src/docs/asciidoc/user-guide/overview.adoc | 2 +- 4 files changed, 16 insertions(+), 16 deletions(-) diff --git a/README.md b/README.md index c1a30d55b379..07d5b9c2296c 100644 --- a/README.md +++ b/README.md @@ -34,7 +34,7 @@ label are specifically targeted for community contributions. ## Getting Help -Ask JUnit 5 related questions on [StackOverflow] or chat with the community on [Gitter]. +Ask JUnit 5 related questions on [StackOverflow] or use the Q&A category on [GitHub Discussions]. ## Continuous Integration Builds @@ -73,14 +73,12 @@ task outputs from previous CI builds. You need [JDK 21] to build JUnit 5. [Gradle toolchains] are used to detect and potentially download additional JDKs for compilation and test execution. -All modules can be _built_ and _tested_ with the [Gradle Wrapper] using the following command. +All modules can be _built_ and _tested_ with the [Gradle Wrapper] using the following command: `./gradlew build` -## Installing in Local Maven Repository - -All modules can be _installed_ with the [Gradle Wrapper] in a local Maven repository for -consumption in other projects via the following command. +All modules can be _installed_ in a local Maven repository for consumption in other local +projects via the following command: `./gradlew publishToMavenLocal` @@ -93,14 +91,11 @@ consumption in other projects via the following command. Consult the [Dependency Metadata] section of the [User Guide] for a list of all artifacts of the JUnit Platform, JUnit Jupiter, and JUnit Vintage. -See also for releases and - for snapshots. - [Codecov]: https://codecov.io/gh/junit-team/junit5 [CONTRIBUTING.md]: https://github.com/junit-team/junit5/blob/HEAD/CONTRIBUTING.md [Dependency Metadata]: https://junit.org/junit5/docs/current/user-guide/#dependency-metadata -[Gitter]: https://gitter.im/junit-team/junit5 +[GitHub Discussions]: https://github.com/junit-team/junit5/discussions/categories/q-a [Gradle toolchains]: https://docs.gradle.org/current/userguide/toolchains.html [Gradle Wrapper]: https://docs.gradle.org/current/userguide/gradle_wrapper.html#sec:using_wrapper [JaCoCo]: https://www.eclemma.org/jacoco/ diff --git a/documentation/src/docs/asciidoc/link-attributes.adoc b/documentation/src/docs/asciidoc/link-attributes.adoc index 2342763e5680..5eb61fe13253 100644 --- a/documentation/src/docs/asciidoc/link-attributes.adoc +++ b/documentation/src/docs/asciidoc/link-attributes.adoc @@ -3,7 +3,7 @@ ifdef::backend-pdf[] :javadoc-root: https://junit.org/junit5/docs/{docs-version}/api endif::[] // Snapshot Repository -:snapshot-repo: https://central.sonatype.com/repository/maven-snapshots +:snapshot-repo: https://central.sonatype.com/service/rest/repository/browse/maven-snapshots // Base Links :junit-team: https://github.com/junit-team :junit5-repo: {junit-team}/junit5 @@ -241,7 +241,7 @@ endif::[] :API: https://apiguardian-team.github.io/apiguardian/docs/current/api/[@API] :API_Guardian: https://github.com/apiguardian-team/apiguardian[@API Guardian] :AssertJ: https://assertj.github.io/doc/[AssertJ] -:Gitter: https://gitter.im/junit-team/junit5[Gitter] +:DiscussionsQA: https://github.com/junit-team/junit5/discussions/categories/q-a[Q&A category on GitHub Discussions] :Hamcrest: https://hamcrest.org/JavaHamcrest/[Hamcrest] :Jimfs: https://google.github.io/jimfs/[Jimfs] :Log4j: https://logging.apache.org/log4j/2.x/[Log4j] diff --git a/documentation/src/docs/asciidoc/user-guide/appendix.adoc b/documentation/src/docs/asciidoc/user-guide/appendix.adoc index 9df8622629d5..060ed2877b08 100644 --- a/documentation/src/docs/asciidoc/user-guide/appendix.adoc +++ b/documentation/src/docs/asciidoc/user-guide/appendix.adoc @@ -17,9 +17,14 @@ artifacts in the repositories were actually generated from this source code. [[dependency-metadata]] === Dependency Metadata -Artifacts for final releases and milestones are deployed to {Maven_Central}, and snapshot -artifacts are deployed to Sonatype's {snapshot-repo}[snapshots repository] under -{snapshot-repo}/org/junit/[/org/junit]. +Artifacts for final releases and milestones are deployed to {Maven_Central}. Consult +https://central.sonatype.org/consume/[Sonatype's documentation] for how to consume those +artifacts with a build tool of your choice. + +Snapshot artifacts are deployed to Sonatype's {snapshot-repo}[snapshots repository] +under {snapshot-repo}/org/junit/[/org/junit]. Please refer to +https://central.sonatype.org/publish/publish-portal-snapshots/#consuming-snapshot-releases-for-your-project[Sonatype's documentation] +for instructions on how to consume them with a build tool of your choice. The sections below list all artifacts with their versions for the three groups: <>, diff --git a/documentation/src/docs/asciidoc/user-guide/overview.adoc b/documentation/src/docs/asciidoc/user-guide/overview.adoc index d06a5eb53eda..4c4f15ec50c2 100644 --- a/documentation/src/docs/asciidoc/user-guide/overview.adoc +++ b/documentation/src/docs/asciidoc/user-guide/overview.adoc @@ -47,7 +47,7 @@ has been compiled with previous versions of the JDK. [[overview-getting-help]] === Getting Help -Ask JUnit 5 related questions on {StackOverflow} or chat with the community on {Gitter}. +Ask JUnit 5 related questions on {StackOverflow} or use the {DiscussionsQA}. [[overview-getting-started]] === Getting Started From ca2ab71d30b12be6f2658bbe45919103badeeba4 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Wed, 18 Jun 2025 07:29:22 +0200 Subject: [PATCH 045/109] Update IntelliJ settings for 2025.1.2 (cherry picked from commit b39ea8c9051aad0c21d72b437b5daf6fef9e31db) --- .idea/codeStyles/Project.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/.idea/codeStyles/Project.xml b/.idea/codeStyles/Project.xml index 9f10a217b5b9..da9a350c8e4c 100644 --- a/.idea/codeStyles/Project.xml +++ b/.idea/codeStyles/Project.xml @@ -7,6 +7,7 @@

Tag expressions are boolean expressions with the following allowed * operators: {@code !} (not), {@code &} (and), and {@code |} (or). Parentheses * can be used to adjust for operator precedence. Please refer to the - * JUnit 5 User Guide + * JUnit 5 User Guide * for usage examples. * *

Please note that a tag name is a valid tag expression. Thus, wherever a tag diff --git a/junit-platform-launcher/src/main/java/org/junit/platform/launcher/core/ClasspathAlignmentChecker.java b/junit-platform-launcher/src/main/java/org/junit/platform/launcher/core/ClasspathAlignmentChecker.java index 3b95f7153e6a..89256c2fda5c 100644 --- a/junit-platform-launcher/src/main/java/org/junit/platform/launcher/core/ClasspathAlignmentChecker.java +++ b/junit-platform-launcher/src/main/java/org/junit/platform/launcher/core/ClasspathAlignmentChecker.java @@ -82,7 +82,7 @@ static Optional check(LinkageError error, FunctionTag expressions are boolean expressions with the following allowed * operators: {@code !} (not), {@code &} (and) and {@code |} (or). Parentheses * can be used to adjust for operator precedence. Please refer to the - * JUnit 5 User Guide + * JUnit 5 User Guide * for usage examples. * *

Syntax Rules for Tags

diff --git a/junit-platform-suite-api/src/main/java/org/junit/platform/suite/api/IncludeTags.java b/junit-platform-suite-api/src/main/java/org/junit/platform/suite/api/IncludeTags.java index 12110bee9bfc..654d8e15a2e6 100644 --- a/junit-platform-suite-api/src/main/java/org/junit/platform/suite/api/IncludeTags.java +++ b/junit-platform-suite-api/src/main/java/org/junit/platform/suite/api/IncludeTags.java @@ -31,7 +31,7 @@ *

Tag expressions are boolean expressions with the following allowed * operators: {@code !} (not), {@code &} (and) and {@code |} (or). Parentheses * can be used to adjust for operator precedence. Please refer to the - * JUnit 5 User Guide + * JUnit 5 User Guide * for usage examples. * *

Syntax Rules for Tags

diff --git a/platform-tests/src/test/java/org/junit/platform/launcher/core/ClasspathAlignmentCheckerTests.java b/platform-tests/src/test/java/org/junit/platform/launcher/core/ClasspathAlignmentCheckerTests.java index c15ad7aa543f..e9b75c3bbd51 100644 --- a/platform-tests/src/test/java/org/junit/platform/launcher/core/ClasspathAlignmentCheckerTests.java +++ b/platform-tests/src/test/java/org/junit/platform/launcher/core/ClasspathAlignmentCheckerTests.java @@ -50,7 +50,7 @@ void wrapsLinkageErrorForUnalignedClasspath() { .hasMessageStartingWith("The wrapped LinkageError is likely caused by the versions of " + "JUnit jars on the classpath/module path not being properly aligned.") // .hasMessageContaining("Please ensure consistent versions are used") // - .hasMessageFindingMatch("https://junit\\.org/junit5/docs/.*/user-guide/#dependency-metadata") // + .hasMessageFindingMatch("https://docs\\.junit\\.org/.*/user-guide/#dependency-metadata") // .hasMessageContaining("The following conflicting versions were detected:") // .hasMessageContaining("- org.junit.jupiter.api: 1.0.0") // .hasMessageContaining("- org.junit.jupiter.engine: 2.0.0") // diff --git a/platform-tooling-support-tests/projects/jupiter-starter/build.xml b/platform-tooling-support-tests/projects/jupiter-starter/build.xml index 79d22fcebc4a..b2c2a3bf08e1 100644 --- a/platform-tooling-support-tests/projects/jupiter-starter/build.xml +++ b/platform-tooling-support-tests/projects/jupiter-starter/build.xml @@ -34,7 +34,7 @@ - + @@ -48,7 +48,7 @@ - + From c2ca731616b16b6f6a303fe042978c3dbd541fe8 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Fri, 20 Jun 2025 15:52:36 +0200 Subject: [PATCH 057/109] Update links to use schemas.junit.org (cherry picked from commit 20b1845f728641e6c4cc5dfc5623a7b868a08862) --- .../reporting/open/xml/OpenTestReportGeneratingListener.java | 3 +-- .../org/junit/platform/reporting/open/xml/catalog.xml | 2 +- .../platform/reporting/open/xml/JUnitContributorTests.java | 2 +- .../open/xml/OpenTestReportGeneratingListenerTests.java | 2 +- .../AntStarterTests_snapshots/open-test-report.xml.snapshot | 2 +- .../GradleStarterTests_snapshots/open-test-report.xml.snapshot | 2 +- .../MavenStarterTests_snapshots/open-test-report.xml.snapshot | 2 +- 7 files changed, 7 insertions(+), 8 deletions(-) diff --git a/junit-platform-reporting/src/main/java/org/junit/platform/reporting/open/xml/OpenTestReportGeneratingListener.java b/junit-platform-reporting/src/main/java/org/junit/platform/reporting/open/xml/OpenTestReportGeneratingListener.java index 954cdc334fc5..4b7ef84dd8a0 100644 --- a/junit-platform-reporting/src/main/java/org/junit/platform/reporting/open/xml/OpenTestReportGeneratingListener.java +++ b/junit-platform-reporting/src/main/java/org/junit/platform/reporting/open/xml/OpenTestReportGeneratingListener.java @@ -134,8 +134,7 @@ public void testPlanExecutionStarted(TestPlan testPlan) { .add("e", Namespace.REPORTING_EVENTS) // .add("git", Namespace.REPORTING_GIT) // .add("java", Namespace.REPORTING_JAVA) // - .add("junit", JUnitFactory.NAMESPACE, - "https://junit.org/junit5/schemas/open-test-reporting/junit-1.9.xsd") // + .add("junit", JUnitFactory.NAMESPACE, "https://schemas.junit.org/open-test-reporting/junit-1.9.xsd") // .build(); outputDir = testPlan.getOutputDirectoryProvider().getRootDirectory(); Path eventsXml = outputDir.resolve("open-test-report.xml"); diff --git a/junit-platform-reporting/src/main/resources/org/junit/platform/reporting/open/xml/catalog.xml b/junit-platform-reporting/src/main/resources/org/junit/platform/reporting/open/xml/catalog.xml index 057d295ac832..d3c5a0eda66d 100644 --- a/junit-platform-reporting/src/main/resources/org/junit/platform/reporting/open/xml/catalog.xml +++ b/junit-platform-reporting/src/main/resources/org/junit/platform/reporting/open/xml/catalog.xml @@ -1,4 +1,4 @@ - + diff --git a/platform-tests/src/test/java/org/junit/platform/reporting/open/xml/JUnitContributorTests.java b/platform-tests/src/test/java/org/junit/platform/reporting/open/xml/JUnitContributorTests.java index e13f7b44fce4..294431df165a 100644 --- a/platform-tests/src/test/java/org/junit/platform/reporting/open/xml/JUnitContributorTests.java +++ b/platform-tests/src/test/java/org/junit/platform/reporting/open/xml/JUnitContributorTests.java @@ -28,7 +28,7 @@ void contributesJUnitSpecificMetadata(@TempDir Path tempDir) throws Exception { """ + xsi:schemaLocation="https://schemas.junit.org/open-test-reporting https://schemas.junit.org/open-test-reporting/junit-1.9.xsd"> [engine:dummy] diff --git a/platform-tests/src/test/java/org/junit/platform/reporting/open/xml/OpenTestReportGeneratingListenerTests.java b/platform-tests/src/test/java/org/junit/platform/reporting/open/xml/OpenTestReportGeneratingListenerTests.java index 80a076abaa59..bf29a1c3c1f2 100644 --- a/platform-tests/src/test/java/org/junit/platform/reporting/open/xml/OpenTestReportGeneratingListenerTests.java +++ b/platform-tests/src/test/java/org/junit/platform/reporting/open/xml/OpenTestReportGeneratingListenerTests.java @@ -108,7 +108,7 @@ void writesValidXmlReport(@TempDir Path tempDirectory) throws Exception { xmlns:java="https://schemas.opentest4j.org/reporting/java/0.2.0" xmlns:junit="https://schemas.junit.org/open-test-reporting" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:schemaLocation="https://schemas.junit.org/open-test-reporting https://junit.org/junit5/schemas/open-test-reporting/junit-1.9.xsd"> + xsi:schemaLocation="https://schemas.junit.org/open-test-reporting https://schemas.junit.org/open-test-reporting/junit-1.9.xsd"> ${xmlunit.ignore} ${xmlunit.ignore} diff --git a/platform-tooling-support-tests/src/test/resources/platform/tooling/support/tests/AntStarterTests_snapshots/open-test-report.xml.snapshot b/platform-tooling-support-tests/src/test/resources/platform/tooling/support/tests/AntStarterTests_snapshots/open-test-report.xml.snapshot index 240a71ef3fd3..b6193859beec 100644 --- a/platform-tooling-support-tests/src/test/resources/platform/tooling/support/tests/AntStarterTests_snapshots/open-test-report.xml.snapshot +++ b/platform-tooling-support-tests/src/test/resources/platform/tooling/support/tests/AntStarterTests_snapshots/open-test-report.xml.snapshot @@ -9,7 +9,7 @@ test-method: ant_starter xmlns:git="https://schemas.opentest4j.org/reporting/git/0.2.0" xmlns:java="https://schemas.opentest4j.org/reporting/java/0.2.0" xmlns:junit="https://schemas.junit.org/open-test-reporting" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://schemas.junit.org/open-test-reporting https://junit.org/junit5/schemas/open-test-reporting/junit-1.9.xsd"> + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://schemas.junit.org/open-test-reporting https://schemas.junit.org/open-test-reporting/junit-1.9.xsd"> obfuscated diff --git a/platform-tooling-support-tests/src/test/resources/platform/tooling/support/tests/GradleStarterTests_snapshots/open-test-report.xml.snapshot b/platform-tooling-support-tests/src/test/resources/platform/tooling/support/tests/GradleStarterTests_snapshots/open-test-report.xml.snapshot index ce4ce4f15535..09377aa77dd2 100644 --- a/platform-tooling-support-tests/src/test/resources/platform/tooling/support/tests/GradleStarterTests_snapshots/open-test-report.xml.snapshot +++ b/platform-tooling-support-tests/src/test/resources/platform/tooling/support/tests/GradleStarterTests_snapshots/open-test-report.xml.snapshot @@ -9,7 +9,7 @@ test-method: buildJupiterStarterProject xmlns:git="https://schemas.opentest4j.org/reporting/git/0.2.0" xmlns:java="https://schemas.opentest4j.org/reporting/java/0.2.0" xmlns:junit="https://schemas.junit.org/open-test-reporting" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://schemas.junit.org/open-test-reporting https://junit.org/junit5/schemas/open-test-reporting/junit-1.9.xsd"> + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://schemas.junit.org/open-test-reporting https://schemas.junit.org/open-test-reporting/junit-1.9.xsd"> obfuscated diff --git a/platform-tooling-support-tests/src/test/resources/platform/tooling/support/tests/MavenStarterTests_snapshots/open-test-report.xml.snapshot b/platform-tooling-support-tests/src/test/resources/platform/tooling/support/tests/MavenStarterTests_snapshots/open-test-report.xml.snapshot index 52ad3af973c1..ee2d20a63f1c 100644 --- a/platform-tooling-support-tests/src/test/resources/platform/tooling/support/tests/MavenStarterTests_snapshots/open-test-report.xml.snapshot +++ b/platform-tooling-support-tests/src/test/resources/platform/tooling/support/tests/MavenStarterTests_snapshots/open-test-report.xml.snapshot @@ -9,7 +9,7 @@ test-method: verifyJupiterStarterProject xmlns:git="https://schemas.opentest4j.org/reporting/git/0.2.0" xmlns:java="https://schemas.opentest4j.org/reporting/java/0.2.0" xmlns:junit="https://schemas.junit.org/open-test-reporting" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://schemas.junit.org/open-test-reporting https://junit.org/junit5/schemas/open-test-reporting/junit-1.9.xsd"> + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://schemas.junit.org/open-test-reporting https://schemas.junit.org/open-test-reporting/junit-1.9.xsd"> obfuscated From 00e0fed273fef75c285774fa16d6568937479dc7 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Fri, 20 Jun 2025 16:45:57 +0200 Subject: [PATCH 058/109] Update links to use junit5 logo (cherry picked from commit 4e55e4368ffe41c94e5b7c629b2be7889a2af383) --- README.md | 2 +- documentation/documentation.gradle.kts | 2 +- documentation/src/docs/asciidoc/docinfos/docinfo.html | 2 +- .../main/kotlin/junitbuild.publishing-conventions.gradle.kts | 2 +- .../commons/support/conversion/ConversionSupportTests.java | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 940c41ad7915..5d6131aea508 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# JUnit 5 +# JUnit 5 This repository is the home of _JUnit 5_. diff --git a/documentation/documentation.gradle.kts b/documentation/documentation.gradle.kts index 6ae15a578bb6..f6f5552ec9f6 100644 --- a/documentation/documentation.gradle.kts +++ b/documentation/documentation.gradle.kts @@ -494,7 +494,7 @@ tasks { } from(inputDir) { filesMatching("**/*.html") { - val favicon = "" + val favicon = "" filter { line -> var result = if (line.startsWith("")) line.replace("", "$favicon") else line externalModulesWithoutModularJavadoc.forEach { (moduleName, baseUrl) -> diff --git a/documentation/src/docs/asciidoc/docinfos/docinfo.html b/documentation/src/docs/asciidoc/docinfos/docinfo.html index 30e46e0a474e..4e2828f34013 100644 --- a/documentation/src/docs/asciidoc/docinfos/docinfo.html +++ b/documentation/src/docs/asciidoc/docinfos/docinfo.html @@ -1,4 +1,4 @@ - +