mirror of
https://github.com/spring-projects/spring-boot.git
synced 2026-09-20 06:29:16 +00:00
Upgrade to Native Build Tools 0.11.0
Closes gh-46501
This commit is contained in:
+5
-1
@@ -48,6 +48,10 @@ public @interface GradleCompatibility {
|
||||
*/
|
||||
boolean configurationCache() default false;
|
||||
|
||||
String versionsLessThan() default "";
|
||||
/**
|
||||
* Minimum version of Gradle against which compatibility should be tested.
|
||||
* @return minimum version
|
||||
*/
|
||||
String minimumVersion() default "";
|
||||
|
||||
}
|
||||
|
||||
+3
-3
@@ -59,10 +59,10 @@ final class GradleCompatibilityExtension implements TestTemplateInvocationContex
|
||||
GradleCompatibility gradleCompatibility = AnnotationUtils.findAnnotation(testClass, GradleCompatibility.class)
|
||||
.get();
|
||||
Stream<String> gradleVersions = GRADLE_VERSIONS.stream();
|
||||
if (StringUtils.hasText(gradleCompatibility.versionsLessThan())) {
|
||||
GradleVersion upperExclusive = GradleVersion.version(gradleCompatibility.versionsLessThan());
|
||||
if (StringUtils.hasText(gradleCompatibility.minimumVersion())) {
|
||||
GradleVersion lowerInclusive = GradleVersion.version(gradleCompatibility.minimumVersion());
|
||||
gradleVersions = gradleVersions
|
||||
.filter((version) -> GradleVersion.version(version).compareTo(upperExclusive) < 0);
|
||||
.filter((version) -> GradleVersion.version(version).compareTo(lowerInclusive) >= 0);
|
||||
}
|
||||
return gradleVersions.flatMap((version) -> {
|
||||
List<TestTemplateInvocationContext> invocationContexts = new ArrayList<>();
|
||||
|
||||
+4
-2
@@ -43,7 +43,7 @@ import static org.assertj.core.api.Assertions.assertThat;
|
||||
* @author Andy Wilkinson
|
||||
* @author Scott Frederick
|
||||
*/
|
||||
@GradleCompatibility
|
||||
@GradleCompatibility(minimumVersion = "8.3")
|
||||
class NativeImagePluginActionIntegrationTests {
|
||||
|
||||
GradleBuild gradleBuild;
|
||||
@@ -111,7 +111,9 @@ class NativeImagePluginActionIntegrationTests {
|
||||
|
||||
@TestTemplate
|
||||
void classesGeneratedDuringAotTestProcessingAreOnTheTestNativeImageClasspath() {
|
||||
BuildResult result = this.gradleBuild.build("checkTestNativeImageClasspath");
|
||||
BuildResult result = this.gradleBuild
|
||||
.scriptProperty("junitVersion", TestTemplate.class.getPackage().getImplementationVersion())
|
||||
.build("checkTestNativeImageClasspath");
|
||||
assertThat(result.getOutput()).contains(projectPath("build/classes/java/aotTest"),
|
||||
projectPath("build/resources/aotTest"), projectPath("build/generated/aotTestClasses"));
|
||||
}
|
||||
|
||||
+4
@@ -25,6 +25,10 @@ repositories {
|
||||
mavenCentral()
|
||||
}
|
||||
|
||||
dependencies {
|
||||
testImplementation("org.junit.jupiter:junit-jupiter:{junitVersion}")
|
||||
}
|
||||
|
||||
task('checkTestNativeImageClasspath') {
|
||||
doFirst {
|
||||
tasks.nativeTestCompile.options.get().classpath.each { println it }
|
||||
|
||||
+1
-1
@@ -17,7 +17,7 @@ junitJupiterVersion=5.13.4
|
||||
kotlinVersion=2.2.0
|
||||
mavenVersion=3.9.10
|
||||
mockitoVersion=5.18.0
|
||||
nativeBuildToolsVersion=0.10.6
|
||||
nativeBuildToolsVersion=0.11.0
|
||||
snakeYamlVersion=2.4
|
||||
springFrameworkVersion=7.0.0-M7
|
||||
springFramework60xVersion=6.0.23
|
||||
|
||||
Reference in New Issue
Block a user