From 5a4b8304b730c23a57e2bfdbc6c9454b62fd7c93 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 1 Oct 2026 17:27:01 +0000 Subject: [PATCH 1/2] Bump mavenVersion from 3.9.16 to 3.10.0 Bumps `mavenVersion` from 3.9.16 to 3.10.0. Updates `org.apache.maven:maven-plugin-api` from 3.9.16 to 3.10.0 - [Release notes](https://github.com/apache/maven/releases) - [Commits](https://github.com/apache/maven/compare/maven-3.9.16...maven-3.10.0) Updates `org.apache.maven:maven-core` from 3.9.16 to 3.10.0 Updates `org.apache.maven:maven-model` from 3.9.16 to 3.10.0 Updates `org.apache.maven:maven-artifact` from 3.9.16 to 3.10.0 --- updated-dependencies: - dependency-name: org.apache.maven:maven-plugin-api dependency-version: 3.10.0 dependency-type: direct:production update-type: version-update:semver-minor - dependency-name: org.apache.maven:maven-core dependency-version: 3.10.0 dependency-type: direct:production update-type: version-update:semver-minor - dependency-name: org.apache.maven:maven-model dependency-version: 3.10.0 dependency-type: direct:production update-type: version-update:semver-minor - dependency-name: org.apache.maven:maven-artifact dependency-version: 3.10.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 28c60c7..f9bb251 100644 --- a/pom.xml +++ b/pom.xml @@ -69,7 +69,7 @@ under the License. 8 - 3.9.16 + 3.10.0 1.9.27 From 0b0d0c0bd0ec016f08322320cf3857fa4f9ad2ef Mon Sep 17 00:00:00 2001 From: Sylwester Lachiewicz Date: Mon, 5 Oct 2026 22:36:20 +0200 Subject: [PATCH 2/2] Align resolver and slf4j with Maven 3.10.0 Maven 3.10.0 ships resolver 2.0.24 and slf4j 2.0.19; keeping resolver 1.9.x and slf4j 1.7.x on the test classpath mixes the two lines and breaks the plugin-testing harness. With resolver 2 the deployment repository carries Intent.DEPLOYMENT, the local repository gains .meta and .locks bookkeeping, and an empty local repository directory may exist after a skipped run; DeployMojoTest accounts for all three. --- pom.xml | 4 ++-- .../maven/plugins/deploy/DeployMojoTest.java | 24 +++++++++++++++---- 2 files changed, 21 insertions(+), 7 deletions(-) diff --git a/pom.xml b/pom.xml index f9bb251..4a86984 100644 --- a/pom.xml +++ b/pom.xml @@ -71,9 +71,9 @@ under the License. 8 3.10.0 - 1.9.27 + 2.0.24 - 1.7.36 + 2.0.19 ${version.maven-antrun-plugin} diff --git a/src/test/java/org/apache/maven/plugins/deploy/DeployMojoTest.java b/src/test/java/org/apache/maven/plugins/deploy/DeployMojoTest.java index cd98529..565b13f 100644 --- a/src/test/java/org/apache/maven/plugins/deploy/DeployMojoTest.java +++ b/src/test/java/org/apache/maven/plugins/deploy/DeployMojoTest.java @@ -50,6 +50,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotNull; import static org.junit.jupiter.api.Assertions.assertNull; +import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.fail; import static org.mockito.Mockito.when; @@ -191,7 +192,8 @@ void testSkippingDeploy(DeployMojo mojo) throws Exception { mojo.execute(); File[] files = localRepo.listFiles(); - assertNull(files); + // the resolver may create an empty local repository directory + assertTrue(files == null || files.length == 0); files = remoteRepo.listFiles(); assertNull(files); @@ -409,7 +411,9 @@ void testNonPomDeployWithAttachedArtifactsOnly(DeployMojo mojo) throws Exception @InjectMojo(goal = "deploy") void testLegacyAltDeploymentRepositoryWithDefaultLayout(DeployMojo mojo) throws Exception { assertEquals( - new RemoteRepository.Builder("altDeploymentRepository", "default", "http://localhost").build(), + new RemoteRepository.Builder("altDeploymentRepository", "default", "http://localhost") + .setIntent(RemoteRepository.Intent.DEPLOYMENT) + .build(), mojo.getDeploymentRepository( mavenProject, null, null, "altDeploymentRepository::default::http://localhost")); } @@ -450,7 +454,9 @@ void testInsaneAltDeploymentRepository(DeployMojo mojo) { @InjectMojo(goal = "deploy") void testDefaultScmSvnAltDeploymentRepository(DeployMojo mojo) throws Exception { assertEquals( - new RemoteRepository.Builder("altDeploymentRepository", "default", "scm:svn:http://localhost").build(), + new RemoteRepository.Builder("altDeploymentRepository", "default", "scm:svn:http://localhost") + .setIntent(RemoteRepository.Intent.DEPLOYMENT) + .build(), mojo.getDeploymentRepository( mavenProject, null, null, "altDeploymentRepository::default::scm:svn:http://localhost")); } @@ -475,7 +481,9 @@ void testLegacyScmSvnAltDeploymentRepository(DeployMojo mojo) { @InjectMojo(goal = "deploy") void testAltSnapshotDeploymentRepository(DeployMojo mojo) throws Exception { assertEquals( - new RemoteRepository.Builder("altSnapshotDeploymentRepository", "default", "http://localhost").build(), + new RemoteRepository.Builder("altSnapshotDeploymentRepository", "default", "http://localhost") + .setIntent(RemoteRepository.Intent.DEPLOYMENT) + .build(), mojo.getDeploymentRepository( mavenProject, "altSnapshotDeploymentRepository::http://localhost", null, null)); } @@ -486,12 +494,18 @@ void testAltReleaseDeploymentRepository(DeployMojo mojo) throws Exception { mavenProject.setVersion("1.0"); assertEquals( - new RemoteRepository.Builder("altReleaseDeploymentRepository", "default", "http://localhost").build(), + new RemoteRepository.Builder("altReleaseDeploymentRepository", "default", "http://localhost") + .setIntent(RemoteRepository.Intent.DEPLOYMENT) + .build(), mojo.getDeploymentRepository( mavenProject, null, "altReleaseDeploymentRepository::http://localhost", null)); } private void addFileToList(File file, List fileList) { + if (".meta".equals(file.getName()) || ".locks".equals(file.getName())) { + // resolver 2.x bookkeeping directories + return; + } if (!file.isDirectory()) { fileList.add(file.getName()); } else {