Upgrade to Gradle 8.12

Closes gh-43649
This commit is contained in:
Andy Wilkinson
2025-01-02 11:12:09 +00:00
parent 734040abe2
commit d8a9ebd14b
20 changed files with 249 additions and 222 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2024 the original author or authors.
* Copyright 2012-2025 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -181,7 +181,7 @@ class BuildInfoTests {
}
private BuildInfo createTask(Project project) {
return project.getTasks().create("testBuildInfo", BuildInfo.class);
return project.getTasks().register("testBuildInfo", BuildInfo.class).get();
}
private Properties buildInfoProperties(BuildInfo task) {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2024 the original author or authors.
* Copyright 2012-2025 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -116,7 +116,7 @@ abstract class AbstractBootArchiveTests<T extends Jar & BootArchive> {
projectDir.mkdirs();
this.project = GradleProjectBuilder.builder().withProjectDir(projectDir).build();
this.project.setDescription("Test project for " + this.taskClass.getSimpleName());
this.task = configure(this.project.getTasks().create("testArchive", this.taskClass));
this.task = this.project.getTasks().register("testArchive", this.taskClass, this::configure).get();
}
@Test

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2024 the original author or authors.
* Copyright 2012-2025 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -57,7 +57,7 @@ class BootBuildImageTests {
projectDir.mkdirs();
this.project = GradleProjectBuilder.builder().withProjectDir(projectDir).withName("build-image-test").build();
this.project.setDescription("Test project for BootBuildImage");
this.buildImage = this.project.getTasks().create("buildImage", BootBuildImage.class);
this.buildImage = this.project.getTasks().register("buildImage", BootBuildImage.class).get();
}
@Test