From 9eb3ee980fc34e7f4a121d8cb1f759aadb90c6d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20=C5=A0irok=C3=BD?= Date: Sun, 1 Jan 2023 00:34:21 +0100 Subject: [PATCH] [MNG-7661] Use provided scope for Maven deps in IT plugins --- .../maven-it-plugin-active-collection/pom.xml | 2 ++ .../core-it-plugins/maven-it-plugin-all/pom.xml | 1 + .../core-it-plugins/maven-it-plugin-artifact/pom.xml | 5 +++++ .../maven-it-plugin-class-loader/pom.xml | 1 + .../maven-it-plugin-configuration/pom.xml | 1 + .../maven-it-plugin-context-passing/pom.xml | 1 + .../maven-clean-plugin/pom.xml | 2 ++ .../maven-compiler-plugin/pom.xml | 2 ++ .../maven-deploy-plugin/pom.xml | 2 ++ .../maven-ear-plugin/pom.xml | 2 ++ .../maven-ejb-plugin/pom.xml | 2 ++ .../maven-install-plugin/pom.xml | 2 ++ .../maven-jar-plugin/pom.xml | 2 ++ .../maven-javadoc-plugin/pom.xml | 2 ++ .../maven-plugin-plugin/pom.xml | 2 ++ .../maven-rar-plugin/pom.xml | 2 ++ .../maven-resources-plugin/pom.xml | 2 ++ .../maven-site-plugin/pom.xml | 2 ++ .../maven-source-plugin/pom.xml | 2 ++ .../maven-surefire-plugin/pom.xml | 2 ++ .../maven-war-plugin/pom.xml | 2 ++ .../maven-it-plugin-dependency-collection/pom.xml | 3 +++ .../maven-it-plugin-dependency-resolution/pom.xml | 3 +++ .../core-it-plugins/maven-it-plugin-error/pom.xml | 1 + .../maven-it-plugin-expression/pom.xml | 1 + .../maven-it-plugin-extension-consumer/pom.xml | 1 + .../maven-it-plugin-extension-provider/pom.xml | 1 + .../maven-it-plugin-extension1/pom.xml | 1 + .../maven-it-plugin-extension2/pom.xml | 1 + .../core-it-plugins/maven-it-plugin-fork/pom.xml | 2 ++ .../maven-it-plugin-invalid-descriptor/pom.xml | 1 + .../core-it-plugins/maven-it-plugin-log-file/pom.xml | 1 + .../core-it-plugins/maven-it-plugin-log4j/pom.xml | 2 ++ .../maven-it-plugin-model-interpolation/pom.xml | 6 ++++++ .../maven-it-plugin-no-default-comp/pom.xml | 1 + .../maven-it-plugin-no-project/pom.xml | 1 + .../core-it-plugins/maven-it-plugin-online/pom.xml | 1 + .../maven-it-plugin-optional-mojos/pom.xml | 1 + .../core-it-plugins/maven-it-plugin-packaging/pom.xml | 1 + .../maven-it-plugin-parameter-implementation/pom.xml | 1 + .../maven-it-plugin-plexus-component-api/pom.xml | 1 + .../maven-it-plugin-plexus-lifecycle/pom.xml | 1 + .../maven-it-plugin-plexus-utils-11/pom.xml | 1 + .../maven-it-plugin-plexus-utils-new/pom.xml | 1 + .../maven-it-plugin-plugin-dependency/pom.xml | 1 + .../maven-it-plugin-project-interpolation/pom.xml | 6 ++++++ .../core-it-plugins/maven-it-plugin-project/pom.xml | 4 ++++ .../core-it-plugins/maven-it-plugin-setter/pom.xml | 1 + .../core-it-plugins/maven-it-plugin-settings/pom.xml | 2 ++ .../maven/plugin/coreit/SettingsReadItMojo.java | 11 +---------- .../maven-it-plugin-singleton-component/pom.xml | 1 + .../core-it-plugins/maven-it-plugin-site/pom.xml | 7 +++++++ .../core-it-plugins/maven-it-plugin-toolchain/pom.xml | 2 ++ .../core-it-plugins/maven-it-plugin-touch/pom.xml | 3 +++ .../maven-it-plugin-uses-properties/pom.xml | 1 + .../maven-it-plugin-uses-wagon/pom.xml | 2 ++ .../pom.xml | 7 ++++--- its/core-it-support/maven-it-plugin-bootstrap/pom.xml | 2 ++ .../org/apache/maven/its/bootstrap/DownloadMojo.java | 3 +-- 59 files changed, 113 insertions(+), 15 deletions(-) diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-active-collection/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-active-collection/pom.xml index 3a636f6c9f..b9d3d9b0db 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-active-collection/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-active-collection/pom.xml @@ -46,11 +46,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-artifact 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-all/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-all/pom.xml index 6e764ff516..d567b263b4 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-all/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-all/pom.xml @@ -43,6 +43,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-artifact/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-artifact/pom.xml index c4741e0451..ad4d1b2684 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-artifact/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-artifact/pom.xml @@ -48,26 +48,31 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided org.apache.maven maven-model 2.0 + provided org.apache.maven maven-artifact 2.0 + provided org.apache.maven maven-repository-metadata 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-class-loader/maven-it-plugin-class-loader/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-class-loader/maven-it-plugin-class-loader/pom.xml index 51b4605ede..1a1db0c62b 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-class-loader/maven-it-plugin-class-loader/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-class-loader/maven-it-plugin-class-loader/pom.xml @@ -44,6 +44,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.junit.jupiter diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-configuration/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-configuration/pom.xml index 6b5975bc7a..3a929ba074 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-configuration/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-configuration/pom.xml @@ -43,6 +43,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.codehaus.plexus diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-context-passing/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-context-passing/pom.xml index d42e92d0df..33c2921b54 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-context-passing/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-context-passing/pom.xml @@ -43,6 +43,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-clean-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-clean-plugin/pom.xml index fabe78e302..459c49fd45 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-clean-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-clean-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-compiler-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-compiler-plugin/pom.xml index 554e5e6776..f4d5408818 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-compiler-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-compiler-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-deploy-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-deploy-plugin/pom.xml index 171af3d3f0..f41efebbd1 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-deploy-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-deploy-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-ear-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-ear-plugin/pom.xml index 9a140f3fe4..5d7f6a425c 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-ear-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-ear-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-ejb-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-ejb-plugin/pom.xml index 6a8d11842f..cfeae4deab 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-ejb-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-ejb-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-install-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-install-plugin/pom.xml index 1ea7d6e00d..d1d88eaa38 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-install-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-install-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-jar-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-jar-plugin/pom.xml index ba9cfcbace..917698c07f 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-jar-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-jar-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-javadoc-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-javadoc-plugin/pom.xml index 9163e49b71..a45501c7ef 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-javadoc-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-javadoc-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-plugin-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-plugin-plugin/pom.xml index f4a043fa56..1ca0946e21 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-plugin-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-plugin-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-rar-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-rar-plugin/pom.xml index 4431463529..be49bab4fd 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-rar-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-rar-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-resources-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-resources-plugin/pom.xml index 024271662e..7267091786 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-resources-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-resources-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-site-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-site-plugin/pom.xml index e0a8840c5a..bb404e8c05 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-site-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-site-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-source-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-source-plugin/pom.xml index 4c01030e6a..6527764b13 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-source-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-source-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-surefire-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-surefire-plugin/pom.xml index c2a1e89e57..5fede8fdab 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-surefire-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-surefire-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-war-plugin/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-war-plugin/pom.xml index f6d9ca3bf9..17eb490072 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-war-plugin/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-core-stubs/maven-war-plugin/pom.xml @@ -49,11 +49,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-dependency-collection/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-dependency-collection/pom.xml index bac13baac1..78999236ca 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-dependency-collection/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-dependency-collection/pom.xml @@ -47,16 +47,19 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided org.apache.maven maven-artifact 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-dependency-resolution/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-dependency-resolution/pom.xml index a4d88f1411..ab3f1f97d3 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-dependency-resolution/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-dependency-resolution/pom.xml @@ -47,11 +47,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.1.0 + provided org.apache.maven @@ -63,6 +65,7 @@ under the License. org.apache.maven maven-artifact 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-error/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-error/pom.xml index 9c1bbbd42a..ed94ba1c66 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-error/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-error/pom.xml @@ -47,6 +47,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided junit diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-expression/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-expression/pom.xml index 4212fe1167..ae7c86cc9f 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-expression/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-expression/pom.xml @@ -43,6 +43,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.junit.jupiter diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-extension-consumer/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-extension-consumer/pom.xml index 4deb9ad725..4ec411794e 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-extension-consumer/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-extension-consumer/pom.xml @@ -46,6 +46,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven.its diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-extension-provider/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-extension-provider/pom.xml index 3d8f35cfce..368dc863a8 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-extension-provider/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-extension-provider/pom.xml @@ -47,6 +47,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven.its diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-extension1/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-extension1/pom.xml index 74a1524615..6fed5a2e1e 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-extension1/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-extension1/pom.xml @@ -45,6 +45,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-extension2/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-extension2/pom.xml index 886d5ffa6b..f3990883b5 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-extension2/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-extension2/pom.xml @@ -46,6 +46,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-fork/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-fork/pom.xml index 2823dca5cf..da2b6e0b0d 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-fork/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-fork/pom.xml @@ -43,11 +43,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided org.codehaus.plexus diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-invalid-descriptor/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-invalid-descriptor/pom.xml index 03be793112..9e27f3ac37 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-invalid-descriptor/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-invalid-descriptor/pom.xml @@ -38,6 +38,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided junit diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-log-file/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-log-file/pom.xml index d6a9d39e35..58bd6ecb16 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-log-file/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-log-file/pom.xml @@ -47,6 +47,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-log4j/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-log4j/pom.xml index 355cfa4bb6..22bd59abb3 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-log4j/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-log4j/pom.xml @@ -47,11 +47,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-artifact 2.0 + provided log4j diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-model-interpolation/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-model-interpolation/pom.xml index 1ec7577f58..ed393266bc 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-model-interpolation/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-model-interpolation/pom.xml @@ -39,11 +39,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.1.0 + provided @@ -55,6 +57,10 @@ under the License. org.apache.maven.shared maven-verifier + + org.apache.maven + maven-artifact + junit junit diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-no-default-comp/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-no-default-comp/pom.xml index 529441a7b3..762d6e11f5 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-no-default-comp/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-no-default-comp/pom.xml @@ -47,6 +47,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.codehaus.plexus diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-no-project/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-no-project/pom.xml index 3e5b2942ba..bff50cfe89 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-no-project/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-no-project/pom.xml @@ -43,6 +43,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-online/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-online/pom.xml index 2e1c57ea24..001e1f98e7 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-online/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-online/pom.xml @@ -46,6 +46,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-optional-mojos/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-optional-mojos/pom.xml index 697d7fecd8..13efb547bc 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-optional-mojos/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-optional-mojos/pom.xml @@ -46,6 +46,7 @@ under the License. org.apache.maven maven-plugin-api 3.0 + provided org.apache.maven.plugin-tools diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-packaging/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-packaging/pom.xml index ed8d5a5d91..40971dc17b 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-packaging/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-packaging/pom.xml @@ -46,6 +46,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-plexus-utils-11/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-plexus-utils-11/pom.xml index 6bd2d2a72b..bda3d07815 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-plexus-utils-11/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-plexus-utils-11/pom.xml @@ -43,6 +43,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided junit diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-plexus-utils-new/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-plexus-utils-new/pom.xml index ca79a43f4b..0ba366af4a 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-plexus-utils-new/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-plexus-utils-new/pom.xml @@ -43,6 +43,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided junit diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-plugin-dependency/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-plugin-dependency/pom.xml index 34c9a37002..6e90c89aff 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-plugin-dependency/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-plugin-dependency/pom.xml @@ -43,6 +43,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided junit diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-project-interpolation/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-project-interpolation/pom.xml index 393125494d..c98341cb34 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-project-interpolation/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-project-interpolation/pom.xml @@ -39,11 +39,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided @@ -55,6 +57,10 @@ under the License. org.apache.maven.shared maven-verifier + + org.apache.maven + maven-artifact + junit junit diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-project/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-project/pom.xml index 3e7375d55d..a99105c384 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-project/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-project/pom.xml @@ -46,21 +46,25 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided org.apache.maven maven-model 2.0 + provided org.apache.maven maven-artifact 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-setter/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-setter/pom.xml index 3928f19a3b..8897ce8c84 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-setter/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-setter/pom.xml @@ -45,6 +45,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-settings/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-settings/pom.xml index 625e1b1946..666b513fea 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-settings/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-settings/pom.xml @@ -42,11 +42,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-settings 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-settings/src/main/java/org/apache/maven/plugin/coreit/SettingsReadItMojo.java b/its/core-it-support/core-it-plugins/maven-it-plugin-settings/src/main/java/org/apache/maven/plugin/coreit/SettingsReadItMojo.java index d812445144..041eebec60 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-settings/src/main/java/org/apache/maven/plugin/coreit/SettingsReadItMojo.java +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-settings/src/main/java/org/apache/maven/plugin/coreit/SettingsReadItMojo.java @@ -23,7 +23,6 @@ import org.apache.maven.plugin.AbstractMojo; import org.apache.maven.plugin.MojoExecutionException; import org.apache.maven.settings.Settings; import org.apache.maven.settings.io.xpp3.SettingsXpp3Writer; -import org.codehaus.plexus.util.IOUtil; import java.io.File; import java.io.FileWriter; @@ -59,10 +58,8 @@ public class SettingsReadItMojo dumpFile.delete(); } dumpFile.getParentFile().mkdirs(); - FileWriter fw = null; - try + try ( FileWriter fw = new FileWriter( dumpFile ) ) { - fw = new FileWriter( dumpFile ); SettingsXpp3Writer writer = new SettingsXpp3Writer(); writer.write( fw, settings ); } @@ -70,11 +67,5 @@ public class SettingsReadItMojo { throw new MojoExecutionException( e.getMessage(), e ); } - finally - { - IOUtil.close( fw ); - } } - - } diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-singleton-component/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-singleton-component/pom.xml index bf50f53c97..0f2f89c429 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-singleton-component/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-singleton-component/pom.xml @@ -46,6 +46,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.codehaus.plexus diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-site/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-site/pom.xml index aa9cfc396e..9f1eb97e10 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-site/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-site/pom.xml @@ -46,6 +46,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven.reporting @@ -67,6 +68,12 @@ under the License. org.apache.maven.reporting maven-reporting-exec 1.6.0 + + + org.apache.maven + * + + diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-toolchain/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-toolchain/pom.xml index c13400e547..38a1029e33 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-toolchain/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-toolchain/pom.xml @@ -38,11 +38,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-toolchain 2.0.10 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-touch/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-touch/pom.xml index 7169276255..4457463502 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-touch/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-touch/pom.xml @@ -40,16 +40,19 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-project 2.0 + provided org.apache.maven maven-artifact 2.0 + provided org.apache.maven diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-uses-properties/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-uses-properties/pom.xml index 43cd3b2546..eeaca5b0a9 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-uses-properties/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-uses-properties/pom.xml @@ -43,6 +43,7 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-uses-wagon/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-uses-wagon/pom.xml index 770e93d37b..c763923958 100644 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-uses-wagon/pom.xml +++ b/its/core-it-support/core-it-plugins/maven-it-plugin-uses-wagon/pom.xml @@ -39,11 +39,13 @@ under the License. org.apache.maven maven-plugin-api 2.0 + provided org.apache.maven maven-artifact-manager 2.0.9 + provided org.codehaus.plexus diff --git a/its/core-it-support/core-it-plugins/mng6759-plugin-resolves-project-dependencies/pom.xml b/its/core-it-support/core-it-plugins/mng6759-plugin-resolves-project-dependencies/pom.xml index ff055d8380..57e8b1183a 100644 --- a/its/core-it-support/core-it-plugins/mng6759-plugin-resolves-project-dependencies/pom.xml +++ b/its/core-it-support/core-it-plugins/mng6759-plugin-resolves-project-dependencies/pom.xml @@ -56,9 +56,10 @@ under the License. provided - org.apache.maven - maven-core - ${maven-version} + org.apache.maven + maven-core + ${maven-version} + provided org.apache.maven diff --git a/its/core-it-support/maven-it-plugin-bootstrap/pom.xml b/its/core-it-support/maven-it-plugin-bootstrap/pom.xml index 841f9efedd..36e035c2ab 100644 --- a/its/core-it-support/maven-it-plugin-bootstrap/pom.xml +++ b/its/core-it-support/maven-it-plugin-bootstrap/pom.xml @@ -42,11 +42,13 @@ under the License. org.apache.maven maven-plugin-api ${mavenVersion} + provided org.apache.maven maven-core ${mavenVersion} + provided org.apache.maven.plugin-tools diff --git a/its/core-it-support/maven-it-plugin-bootstrap/src/main/java/org/apache/maven/its/bootstrap/DownloadMojo.java b/its/core-it-support/maven-it-plugin-bootstrap/src/main/java/org/apache/maven/its/bootstrap/DownloadMojo.java index 4e3a24652c..64e258d46e 100644 --- a/its/core-it-support/maven-it-plugin-bootstrap/src/main/java/org/apache/maven/its/bootstrap/DownloadMojo.java +++ b/its/core-it-support/maven-it-plugin-bootstrap/src/main/java/org/apache/maven/its/bootstrap/DownloadMojo.java @@ -37,7 +37,6 @@ import org.apache.maven.plugins.annotations.Component; import org.apache.maven.plugins.annotations.Mojo; import org.apache.maven.plugins.annotations.Parameter; import org.apache.maven.project.ProjectBuildingRequest; -import org.codehaus.plexus.util.StringUtils; import org.eclipse.aether.RepositorySystem; import org.eclipse.aether.RepositorySystemSession; import org.eclipse.aether.artifact.ArtifactTypeRegistry; @@ -132,7 +131,7 @@ public class DownloadMojo throws MojoFailureException { Dependency coordinate = new Dependency(); - String[] tokens = StringUtils.split( artifact, ":" ); + String[] tokens = artifact.split( ":" ); if ( tokens.length < 3 || tokens.length > 5 ) { throw new MojoFailureException( "Invalid artifact, you must specify "