diff --git a/.idea/icon.png b/.idea/icon.png deleted file mode 100644 index 0af0c138f7e9..000000000000 Binary files a/.idea/icon.png and /dev/null differ diff --git a/rewrite-maven/src/test/java/org/openrewrite/maven/ChangeParentPomTest.java b/rewrite-maven/src/test/java/org/openrewrite/maven/ChangeParentPomTest.java index 4746e3e07186..f82782ab74ec 100644 --- a/rewrite-maven/src/test/java/org/openrewrite/maven/ChangeParentPomTest.java +++ b/rewrite-maven/src/test/java/org/openrewrite/maven/ChangeParentPomTest.java @@ -80,6 +80,103 @@ void changeParent() { ); } + @Test + void changeParentShouldResolveDependenciesMangementWithMavenProperties() { + rewriteRun( + spec -> spec.recipe(new ChangeParentPom( + "org.jenkins-ci.plugins", + "org.jenkins-ci.plugins", + "plugin", + "plugin", + "5.3", + null, + null, + null, + false + )), + pomXml( + """ + + + org.jenkins-ci.plugins + plugin + 4.86 + + + example-plugin + 0.8-SNAPSHOT + + 2.462 + ${jenkins.baseline}.3 + + + + + io.jenkins.tools.bom + bom-${jenkins.baseline}.x + 3722.vcc62e7311580 + pom + import + + + + + + org.jenkins-ci.plugins + scm-api + + + + + repo.jenkins-ci.org + https://repo.jenkins-ci.org/public/ + + + + """, + """ + + + org.jenkins-ci.plugins + plugin + 5.3 + + + example-plugin + 0.8-SNAPSHOT + + 2.462 + ${jenkins.baseline}.3 + + + + + io.jenkins.tools.bom + bom-${jenkins.baseline}.x + 3722.vcc62e7311580 + pom + import + + + + + + org.jenkins-ci.plugins + scm-api + + + + + repo.jenkins-ci.org + https://repo.jenkins-ci.org/public/ + + + + """ + ) + ); + } + @Test void changeParentWithRelativePath() { rewriteRun(