This is an automated email from the ASF dual-hosted git repository. slachiewicz pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/maven-release.git
commit 831febc0e0a39ea5ee515ec899d2cedfae4ddfcc Author: Sylwester Lachiewicz <[email protected]> AuthorDate: Wed Nov 25 22:28:23 2026 +0000 Format Groovy IT scripts Formatting only: the CONVERSION-phase AST of every file is unchanged. See https://github.com/apache/maven-invoker-plugin/issues/811. --- .../it/projects/branch/MRELEASE-458/verify.groovy | 2 +- .../it/projects/branch/MRELEASE-694/verify.groovy | 6 +++--- .../it/projects/branch/MRELEASE-745/verify.groovy | 2 +- .../it/projects/branch/MRELEASE-976/verify.groovy | 6 +++--- .../src/it/projects/branch/gh-1420/verify.groovy | 12 +++++------ .../it/projects/perform/MRELEASE-459/verify.groovy | 6 +++--- .../it/projects/perform/MRELEASE-818/verify.groovy | 4 ++-- .../it/projects/perform/MRELEASE-832/verify.groovy | 6 +++--- .../src/it/projects/perform/gh-1040/verify.groovy | 6 +++--- .../prepare-with-pom/MRELEASE-808/verify.groovy | 2 +- .../prepare-with-pom/finalname-basic/verify.groovy | 2 +- .../finalname-multimodule/verify.groovy | 2 +- .../projects/prepare/MRELEASE-1053/verify.groovy | 6 +++--- .../projects/prepare/MRELEASE-1077/verify.groovy | 6 +++--- .../it/projects/prepare/MRELEASE-156/verify.groovy | 12 +++++------ .../verify.groovy | 4 ++-- .../it/projects/prepare/MRELEASE-161/verify.groovy | 4 ++-- .../it/projects/prepare/MRELEASE-420/verify.groovy | 2 +- .../it/projects/prepare/MRELEASE-483/verify.groovy | 2 +- .../it/projects/prepare/MRELEASE-533/verify.groovy | 2 +- .../projects/prepare/MRELEASE-571_M3/verify.groovy | 6 +++--- .../it/projects/prepare/MRELEASE-618/verify.groovy | 2 +- .../it/projects/prepare/MRELEASE-667/verify.groovy | 4 ++-- .../it/projects/prepare/MRELEASE-835/verify.groovy | 4 ++-- .../it/projects/prepare/MRELEASE-966/verify.groovy | 2 +- .../it/projects/prepare/MRELEASE-976/verify.groovy | 6 +++--- .../it/projects/prepare/MRELEASE-985/verify.groovy | 6 +++--- .../prepare/ci-friendly-multi-module/verify.groovy | 14 ++++++------- .../prepare/completion-goals/verify.groovy | 2 +- .../prepare/fail-on-snapshots/verify.groovy | 24 ++++++++++++++-------- .../flat-multi-module/parent-project/verify.groovy | 6 +++--- .../src/it/projects/prepare/gh-1420/verify.groovy | 12 +++++------ .../it/projects/prepare/namespace/verify.groovy | 6 +++--- .../projects/prepare/version-policy/verify.groovy | 14 ++++++------- .../MRELEASE-1104-both-parameters/verify.groovy | 4 ++-- .../MRELEASE-1104-stage-repo-only/verify.groovy | 4 ++-- .../update-versions/MRELEASE-555/verify.groovy | 6 +++--- .../update-versions/MRELEASE-611/verify.groovy | 6 +++--- .../update-versions/MRELEASE-976/verify.groovy | 2 +- 39 files changed, 114 insertions(+), 110 deletions(-) diff --git a/maven-release-plugin/src/it/projects/branch/MRELEASE-458/verify.groovy b/maven-release-plugin/src/it/projects/branch/MRELEASE-458/verify.groovy index a10fe16b..a5c75f7f 100644 --- a/maven-release-plugin/src/it/projects/branch/MRELEASE-458/verify.groovy +++ b/maven-release-plugin/src/it/projects/branch/MRELEASE-458/verify.groovy @@ -17,7 +17,7 @@ * under the License. */ -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() assert buildLog.getText().contains("[INFO] Full run would be commit 1 files with message: '[maven-release-plugin] prepare branch test-1.0.x'") diff --git a/maven-release-plugin/src/it/projects/branch/MRELEASE-694/verify.groovy b/maven-release-plugin/src/it/projects/branch/MRELEASE-694/verify.groovy index 3514168c..4f6c1303 100644 --- a/maven-release-plugin/src/it/projects/branch/MRELEASE-694/verify.groovy +++ b/maven-release-plugin/src/it/projects/branch/MRELEASE-694/verify.groovy @@ -20,15 +20,15 @@ import groovy.xml.XmlSlurper -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() assert buildLog.getText().contains("[INFO] Full run would be commit 1 files with message: '[maven-release-plugin] prepare branch RELEASE-2.6.0'") -def projectBranch = new XmlSlurper().parse( new File( basedir, "pom.xml.branch" ) ) +def projectBranch = new XmlSlurper().parse(new File(basedir, "pom.xml.branch")) assert projectBranch.version.text() == "2.6.0-BRANCH-SNAPSHOT" -def projectNext = new XmlSlurper().parse( new File( basedir, "pom.xml.next" ) ) +def projectNext = new XmlSlurper().parse(new File(basedir, "pom.xml.next")) assert projectNext.version.text() == "2.6.1-DEV-SNAPSHOT" return true diff --git a/maven-release-plugin/src/it/projects/branch/MRELEASE-745/verify.groovy b/maven-release-plugin/src/it/projects/branch/MRELEASE-745/verify.groovy index ddc0d4c4..1a47a1c5 100644 --- a/maven-release-plugin/src/it/projects/branch/MRELEASE-745/verify.groovy +++ b/maven-release-plugin/src/it/projects/branch/MRELEASE-745/verify.groovy @@ -18,7 +18,7 @@ * under the License. */ -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() assert 1 == buildLog.getText().count("[INFO] Full run would not commit changes, because suppressCommitBeforeTagOrBranch is set.") diff --git a/maven-release-plugin/src/it/projects/branch/MRELEASE-976/verify.groovy b/maven-release-plugin/src/it/projects/branch/MRELEASE-976/verify.groovy index 93aaa822..88fe4e95 100644 --- a/maven-release-plugin/src/it/projects/branch/MRELEASE-976/verify.groovy +++ b/maven-release-plugin/src/it/projects/branch/MRELEASE-976/verify.groovy @@ -20,14 +20,14 @@ import groovy.xml.XmlSlurper -def project = new XmlSlurper().parse( new File( basedir, "pom.xml" ) ) +def project = new XmlSlurper().parse(new File(basedir, "pom.xml")) assert project.version.text() == "1.0-SNAPSHOT" // verifies that the version is unchanged because of the custom policy: 1.0-SNAPSHOT -> 1.0-SNAPSHOT -def projectNext = new XmlSlurper().parse( new File( basedir, "pom.xml.next" ) ) +def projectNext = new XmlSlurper().parse(new File(basedir, "pom.xml.next")) assert projectNext.version.text() == "1.0-SNAPSHOT" -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() assert buildLog.getText().contains("[INFO] Full run would be commit 1 files with message: '[maven-release-plugin] prepare branch branch-mrelease-976'") diff --git a/maven-release-plugin/src/it/projects/branch/gh-1420/verify.groovy b/maven-release-plugin/src/it/projects/branch/gh-1420/verify.groovy index 086f8a18..35ba617b 100644 --- a/maven-release-plugin/src/it/projects/branch/gh-1420/verify.groovy +++ b/maven-release-plugin/src/it/projects/branch/gh-1420/verify.groovy @@ -19,26 +19,26 @@ import groovy.xml.XmlSlurper -def pom = new XmlSlurper().parse( new File( basedir, 'pom.xml.branch' ) ) +def pom = new XmlSlurper().parse(new File(basedir, 'pom.xml.branch')) assert pom.scm.tag.text() == 'gh-1420-1.0-SNAPSHOT' assert pom.version.text() == '1.0-SNAPSHOT' -def pomNext = new XmlSlurper().parse( new File( basedir, 'pom.xml.next' ) ) +def pomNext = new XmlSlurper().parse(new File(basedir, 'pom.xml.next')) assert pomNext.scm.tag.text() == 'HEAD' assert pomNext.version.text() == '1.1-SNAPSHOT' -def pom1 = new XmlSlurper().parse( new File( basedir, 'module1/pom.xml.branch' ) ) +def pom1 = new XmlSlurper().parse(new File(basedir, 'module1/pom.xml.branch')) assert pom1.scm.size() == 0 assert pom1.parent.version.text() == '1.0-SNAPSHOT' -def pom1Next = new XmlSlurper().parse( new File( basedir, 'module1/pom.xml.next' ) ) +def pom1Next = new XmlSlurper().parse(new File(basedir, 'module1/pom.xml.next')) assert pom1Next.scm.size() == 0 assert pom1Next.parent.version.text() == '1.1-SNAPSHOT' -def pom2 = new XmlSlurper().parse( new File( basedir, 'module1/module2/pom.xml.branch' ) ) +def pom2 = new XmlSlurper().parse(new File(basedir, 'module1/module2/pom.xml.branch')) assert pom2.scm.size() == 0 assert pom2.parent.version.text() == '1.0-SNAPSHOT' -def pom2Next = new XmlSlurper().parse( new File( basedir, 'module1/module2/pom.xml.next' ) ) +def pom2Next = new XmlSlurper().parse(new File(basedir, 'module1/module2/pom.xml.next')) assert pom2Next.scm.size() == 0 assert pom2Next.parent.version.text() == '1.1-SNAPSHOT' diff --git a/maven-release-plugin/src/it/projects/perform/MRELEASE-459/verify.groovy b/maven-release-plugin/src/it/projects/perform/MRELEASE-459/verify.groovy index 7f09bf2f..3210a072 100644 --- a/maven-release-plugin/src/it/projects/perform/MRELEASE-459/verify.groovy +++ b/maven-release-plugin/src/it/projects/perform/MRELEASE-459/verify.groovy @@ -17,11 +17,11 @@ * under the License. */ -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() def addArgsExpr = /\Q[INFO] with additional arguments: \E(?:-Dhttps.protocols=TLSv1.2 )?-P(.+)\Q-DperformRelease=true -f pom.xml\E/ -def matcher = ( buildLog.getText() =~ addArgsExpr ) +def matcher = (buildLog.getText() =~ addArgsExpr) // M2: [INFO] with additional arguments: -P custom-release -DperformRelease=true -f pom.xml // M3: [INFO] with additional arguments: -P it-repo,it-repo,custom-release -DperformRelease=true -f pom.xml @@ -29,4 +29,4 @@ def matcher = ( buildLog.getText() =~ addArgsExpr ) assert matcher.find() assert matcher.getCount() == 1 -assert matcher[0][1].contains( "custom-release" ) +assert matcher[0][1].contains("custom-release") diff --git a/maven-release-plugin/src/it/projects/perform/MRELEASE-818/verify.groovy b/maven-release-plugin/src/it/projects/perform/MRELEASE-818/verify.groovy index 89f178ae..8e3def03 100644 --- a/maven-release-plugin/src/it/projects/perform/MRELEASE-818/verify.groovy +++ b/maven-release-plugin/src/it/projects/perform/MRELEASE-818/verify.groovy @@ -17,11 +17,11 @@ * under the License. */ -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() def localCheckoutExpr = /\Q[INFO] The project would have a local check out to perform the release from / -def matcher = ( buildLog.getText() =~ localCheckoutExpr ) +def matcher = (buildLog.getText() =~ localCheckoutExpr) assert matcher.find() assert matcher.getCount() == 1 \ No newline at end of file diff --git a/maven-release-plugin/src/it/projects/perform/MRELEASE-832/verify.groovy b/maven-release-plugin/src/it/projects/perform/MRELEASE-832/verify.groovy index 96d8b7ec..a0e2a72e 100644 --- a/maven-release-plugin/src/it/projects/perform/MRELEASE-832/verify.groovy +++ b/maven-release-plugin/src/it/projects/perform/MRELEASE-832/verify.groovy @@ -17,9 +17,9 @@ * under the License. */ -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() -assert buildLog.text.contains( "[DEBUG] (f) username = perform_username" ) -assert buildLog.text.contains( "[DEBUG] (f) password = perform_password" ) +assert buildLog.text.contains("[DEBUG] (f) username = perform_username") +assert buildLog.text.contains("[DEBUG] (f) password = perform_password") diff --git a/maven-release-plugin/src/it/projects/perform/gh-1040/verify.groovy b/maven-release-plugin/src/it/projects/perform/gh-1040/verify.groovy index 146adbcd..4231d1f7 100644 --- a/maven-release-plugin/src/it/projects/perform/gh-1040/verify.groovy +++ b/maven-release-plugin/src/it/projects/perform/gh-1040/verify.groovy @@ -19,9 +19,9 @@ import groovy.xml.XmlSlurper -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() -assert buildLog.text.contains( "Checking out: " + new File( basedir, 'tags/gh-1040-1.0' ).absolutePath ) +assert buildLog.text.contains("Checking out: " + new File(basedir, 'tags/gh-1040-1.0').absolutePath) -def pom = new XmlSlurper().parse( new File( basedir, 'target/checkout/pom.xml' ) ) +def pom = new XmlSlurper().parse(new File(basedir, 'target/checkout/pom.xml')) assert pom.version.text() == '1.0' diff --git a/maven-release-plugin/src/it/projects/prepare-with-pom/MRELEASE-808/verify.groovy b/maven-release-plugin/src/it/projects/prepare-with-pom/MRELEASE-808/verify.groovy index 426eebf8..9c398c2f 100644 --- a/maven-release-plugin/src/it/projects/prepare-with-pom/MRELEASE-808/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare-with-pom/MRELEASE-808/verify.groovy @@ -18,7 +18,7 @@ * under the License. */ -File releasePom = new File( basedir, 'release-pom.xml' ) +File releasePom = new File(basedir, 'release-pom.xml') assert releasePom.exists() assert 1 == releasePom.getText().count("<finalName>org.apache.maven.plugin.release.its.mrelease-808-1.0</finalName>") diff --git a/maven-release-plugin/src/it/projects/prepare-with-pom/finalname-basic/verify.groovy b/maven-release-plugin/src/it/projects/prepare-with-pom/finalname-basic/verify.groovy index fdec012c..4ff7050f 100644 --- a/maven-release-plugin/src/it/projects/prepare-with-pom/finalname-basic/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare-with-pom/finalname-basic/verify.groovy @@ -18,7 +18,7 @@ * under the License. */ -File releasePom = new File( basedir, 'release-pom.xml' ) +File releasePom = new File(basedir, 'release-pom.xml') assert releasePom.exists() assert 1 == releasePom.getText().count("<finalName>finalname-basic-1.0</finalName>") diff --git a/maven-release-plugin/src/it/projects/prepare-with-pom/finalname-multimodule/verify.groovy b/maven-release-plugin/src/it/projects/prepare-with-pom/finalname-multimodule/verify.groovy index 308277e3..ee447388 100644 --- a/maven-release-plugin/src/it/projects/prepare-with-pom/finalname-multimodule/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare-with-pom/finalname-multimodule/verify.groovy @@ -18,7 +18,7 @@ * under the License. */ -File moduleReleasePom = new File( basedir, 'module/release-pom.xml' ) +File moduleReleasePom = new File(basedir, 'module/release-pom.xml') assert moduleReleasePom.exists() assert 1 == moduleReleasePom.getText().count("<finalName>FinalName</finalName>") diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-1053/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-1053/verify.groovy index e12d0e57..7ba1c889 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-1053/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-1053/verify.groovy @@ -20,14 +20,14 @@ import groovy.xml.XmlSlurper // check parent project -def project = new XmlSlurper().parse( new File( new File ( basedir, 'module-parent' ), 'pom.xml.next' ) ) +def project = new XmlSlurper().parse(new File(new File(basedir, 'module-parent'), 'pom.xml.next')) assert project.version.text() == '1.1-SNAPSHOT' assert project.scm.url.text() == 'http://localhost/myscm/${project.scm.tag}' // check execution root project -project = new XmlSlurper().parse( new File ( basedir, 'pom.xml.next' ) ) +project = new XmlSlurper().parse(new File(basedir, 'pom.xml.next')) assert 0 == project.scm.size() // scm element must not exist in reactor root // check module-a project -project = new XmlSlurper().parse( new File( new File ( basedir, 'module-a' ), 'pom.xml.next' ) ) +project = new XmlSlurper().parse(new File(new File(basedir, 'module-a'), 'pom.xml.next')) assert 0 == project.scm.size() // scm element must not exist in module diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-1077/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-1077/verify.groovy index 563380f8..e7f4d8af 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-1077/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-1077/verify.groovy @@ -17,8 +17,8 @@ * under the License. */ -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() -assert buildLog.text.contains( "[INFO] - PrepProfA (source: ") -assert buildLog.text.contains( "[INFO] - PrepProfB (source: ") +assert buildLog.text.contains("[INFO] - PrepProfA (source: ") +assert buildLog.text.contains("[INFO] - PrepProfB (source: ") diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-156/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-156/verify.groovy index 22c52b01..41046fa4 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-156/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-156/verify.groovy @@ -18,14 +18,12 @@ * under the License. */ -File releaseProperties = new File( basedir, 'release.properties' ) +File releaseProperties = new File(basedir, 'release.properties') assert releaseProperties.exists() -if ( System.properties[ 'os.name' ].toLowerCase().contains( 'windows' ) ) -{ - assert 1 == releaseProperties.getText().count( "scm.commentPrefix=ABCD-1234\\r\\n" ) +if (System.properties['os.name'].toLowerCase().contains('windows')) { + assert 1 == releaseProperties.getText().count("scm.commentPrefix=ABCD-1234\\r\\n") } -else -{ - assert 1 == releaseProperties.getText().count( "scm.commentPrefix=ABCD-1234\\n" ) +else { + assert 1 == releaseProperties.getText().count("scm.commentPrefix=ABCD-1234\\n") } \ No newline at end of file diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-161-dependencyManagement/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-161-dependencyManagement/verify.groovy index f978353e..e51da996 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-161-dependencyManagement/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-161-dependencyManagement/verify.groovy @@ -21,10 +21,10 @@ import groovy.xml.XmlSlurper -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() -def projectRoot = new XmlSlurper().parse( new File( basedir, "pom.xml.next" ) ) +def projectRoot = new XmlSlurper().parse(new File(basedir, "pom.xml.next")) assert projectRoot.dependencyManagement.dependencies.dependency[0].version.text() == "1.1-SNAPSHOT" assert projectRoot.dependencyManagement.dependencies.dependency[1].version.text() == "1.1-SNAPSHOT" diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-161/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-161/verify.groovy index 13707099..31b675bc 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-161/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-161/verify.groovy @@ -20,10 +20,10 @@ import groovy.xml.XmlSlurper -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() -def projectRoot = new XmlSlurper().parse( new File( basedir, "release-test-module-two/pom.xml.next" ) ) +def projectRoot = new XmlSlurper().parse(new File(basedir, "release-test-module-two/pom.xml.next")) assert projectRoot.dependencies.dependency[0].version.text() == "1.1-SNAPSHOT" assert projectRoot.dependencies.dependency[1].version.text() == "1.1-SNAPSHOT" diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-420/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-420/verify.groovy index a41f9c30..6671efbd 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-420/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-420/verify.groovy @@ -18,7 +18,7 @@ * under the License. */ -File releaseProperties = new File( basedir, 'release.properties' ) +File releaseProperties = new File(basedir, 'release.properties') assert releaseProperties.exists() assert 1 == releaseProperties.getText().count("scm.id=it-server") diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-483/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-483/verify.groovy index 3db65ae0..cfac0cbc 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-483/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-483/verify.groovy @@ -18,7 +18,7 @@ * under the License. */ -File releaseProperties = new File( basedir, 'release.properties' ) +File releaseProperties = new File(basedir, 'release.properties') assert releaseProperties.exists() assert 1 == releaseProperties.getText().count("project.dev.org.apache.maven.plugin.release.its\\:mrelease-483=1.0-SNAPSHOT") diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-533/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-533/verify.groovy index f34ab175..2496759a 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-533/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-533/verify.groovy @@ -18,7 +18,7 @@ * under the License. */ -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() assert 1 == buildLog.getText().count("[DEBUG] Specified POM file is not named 'pom.xml'. Using the '-f' command-line option to accommodate non-standard filename...") diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-571_M3/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-571_M3/verify.groovy index e0839d3d..c2628341 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-571_M3/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-571_M3/verify.groovy @@ -17,11 +17,11 @@ * under the License. */ -File releaseProperties = new File( basedir, 'release.properties' ) +File releaseProperties = new File(basedir, 'release.properties') assert releaseProperties.exists() def String execArgs = releaseProperties.filterLine { line -> - line.startsWith( 'exec.activateProfiles=' ) + line.startsWith('exec.activateProfiles=') } -assert execArgs.contains( "mrelease571" ) +assert execArgs.contains("mrelease571") diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-618/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-618/verify.groovy index f34ab175..2496759a 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-618/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-618/verify.groovy @@ -18,7 +18,7 @@ * under the License. */ -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() assert 1 == buildLog.getText().count("[DEBUG] Specified POM file is not named 'pom.xml'. Using the '-f' command-line option to accommodate non-standard filename...") diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-667/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-667/verify.groovy index 215d58ef..c31bba8e 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-667/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-667/verify.groovy @@ -18,10 +18,10 @@ * under the License. */ -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() -// Can only be checked with M3 +// Can only be checked with M3 //assert 1 == buildLog.getText().count("[DEBUG] Profile with id: 'mrelease-677' has been explicitly activated.") assert 1 == buildLog.getText().count(" Profile Id: mrelease-677 (Active: false, Source: settings.xml)") diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-835/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-835/verify.groovy index 027cc503..042e7bf7 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-835/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-835/verify.groovy @@ -17,12 +17,12 @@ * under the License. */ -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() assert 1 == buildLog.getText().count("[DEBUG] (f) autoResolveSnapshots = dependencies") -File pomXmlNext = new File( basedir, 'pom.xml.next' ) +File pomXmlNext = new File(basedir, 'pom.xml.next') assert pomXmlNext.exists() assert 1 == pomXmlNext.getText().count("<version>1.2.3</version>") assert 1 == pomXmlNext.getText().count("<version>2.3.4</version>") diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-966/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-966/verify.groovy index a39cde10..7c83a62a 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-966/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-966/verify.groovy @@ -18,7 +18,7 @@ * under the License. */ -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() assert 2 == buildLog.getText().count("[INFO] Building mrelease-966-my-pom 1.0-SNAPSHOT") diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-976/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-976/verify.groovy index bd1a9e41..a9a76039 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-976/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-976/verify.groovy @@ -20,13 +20,13 @@ import groovy.xml.XmlSlurper -def project = new XmlSlurper().parse( new File( basedir, "pom.xml" ) ) +def project = new XmlSlurper().parse(new File(basedir, "pom.xml")) assert project.version.text() == "1.0-SNAPSHOT" -def projectTag = new XmlSlurper().parse( new File( basedir, "pom.xml.tag" ) ) +def projectTag = new XmlSlurper().parse(new File(basedir, "pom.xml.tag")) assert projectTag.version.text() == "1.0" -def projectNext = new XmlSlurper().parse( new File( basedir, "pom.xml.next" ) ) +def projectNext = new XmlSlurper().parse(new File(basedir, "pom.xml.next")) assert projectNext.version.text() == "1.0-SNAPSHOT" return true diff --git a/maven-release-plugin/src/it/projects/prepare/MRELEASE-985/verify.groovy b/maven-release-plugin/src/it/projects/prepare/MRELEASE-985/verify.groovy index bbd0de78..8c47e030 100644 --- a/maven-release-plugin/src/it/projects/prepare/MRELEASE-985/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/MRELEASE-985/verify.groovy @@ -20,17 +20,17 @@ import groovy.xml.XmlSlurper -def project = new XmlSlurper().parse( new File( basedir, "pom.xml" ) ) +def project = new XmlSlurper().parse(new File(basedir, "pom.xml")) assert project.version.text() == "1.0-SNAPSHOT" assert project.parent.version.text() == "1-SNAPSHOT" assert project.dependencies.dependency.version.text() == "1.0-SNAPSHOT" -def projectTag = new XmlSlurper().parse( new File( basedir, "pom.xml.tag" ) ) +def projectTag = new XmlSlurper().parse(new File(basedir, "pom.xml.tag")) assert projectTag.version.text() == "1.0" assert projectTag.parent.version.text() == "1" assert projectTag.dependencies.dependency.version.text() == "1.0.RELEASE" -def projectNext = new XmlSlurper().parse( new File( basedir, "pom.xml.next" ) ) +def projectNext = new XmlSlurper().parse(new File(basedir, "pom.xml.next")) assert projectNext.version.text() == "1.1-SNAPSHOT" assert projectNext.parent.version.text() == "2-SNAPSHOT" assert projectNext.dependencies.dependency.version.text() == "2.0-SNAPSHOT" diff --git a/maven-release-plugin/src/it/projects/prepare/ci-friendly-multi-module/verify.groovy b/maven-release-plugin/src/it/projects/prepare/ci-friendly-multi-module/verify.groovy index 2b83f5f9..bd2d1e1c 100644 --- a/maven-release-plugin/src/it/projects/prepare/ci-friendly-multi-module/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/ci-friendly-multi-module/verify.groovy @@ -19,34 +19,34 @@ import groovy.xml.XmlSlurper -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() // tag versions -def projectRootTag = new XmlSlurper().parse( new File( basedir, 'pom.xml.tag' ) ) +def projectRootTag = new XmlSlurper().parse(new File(basedir, 'pom.xml.tag')) assert projectRootTag.version.text() == '${revision}${sha1}${changelist}' assert projectRootTag.properties.revision.text() == "1.0.0" assert projectRootTag.properties.sha1.text() == "-abcdef12" assert projectRootTag.properties.changelist.text() == "" -def projectATag = new XmlSlurper().parse( new File( basedir, 'module-a/pom.xml.tag' ) ) +def projectATag = new XmlSlurper().parse(new File(basedir, 'module-a/pom.xml.tag')) assert projectATag.parent.version.text() == '${revision}${sha1}${changelist}' -def projectBTag = new XmlSlurper().parse( new File( basedir, 'module-b/pom.xml.tag' ) ) +def projectBTag = new XmlSlurper().parse(new File(basedir, 'module-b/pom.xml.tag')) assert projectBTag.parent.version.text() == '${revision}${sha1}${changelist}' // next development versions -def projectRoot = new XmlSlurper().parse( new File( basedir, 'pom.xml.next' ) ) +def projectRoot = new XmlSlurper().parse(new File(basedir, 'pom.xml.next')) assert projectRoot.version.text() == '${revision}${sha1}${changelist}' assert projectRoot.properties.revision.text() == "1.0.1" assert projectRoot.properties.sha1.text() == "" assert projectRoot.properties.changelist.text() == "-SNAPSHOT" -def projectA = new XmlSlurper().parse( new File( basedir, 'module-a/pom.xml.next' ) ) +def projectA = new XmlSlurper().parse(new File(basedir, 'module-a/pom.xml.next')) assert projectA.parent.version.text() == '${revision}${sha1}${changelist}' -def projectB = new XmlSlurper().parse( new File( basedir, 'module-b/pom.xml.next' ) ) +def projectB = new XmlSlurper().parse(new File(basedir, 'module-b/pom.xml.next')) assert projectB.parent.version.text() == '${revision}${sha1}${changelist}' return true diff --git a/maven-release-plugin/src/it/projects/prepare/completion-goals/verify.groovy b/maven-release-plugin/src/it/projects/prepare/completion-goals/verify.groovy index 628e6b46..63799b57 100644 --- a/maven-release-plugin/src/it/projects/prepare/completion-goals/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/completion-goals/verify.groovy @@ -17,7 +17,7 @@ * under the License. */ -File buildLog = new File( basedir, "build.log" ) +File buildLog = new File(basedir, "build.log") println "Checking logs.." diff --git a/maven-release-plugin/src/it/projects/prepare/fail-on-snapshots/verify.groovy b/maven-release-plugin/src/it/projects/prepare/fail-on-snapshots/verify.groovy index 7bc9f5fb..3e05d23b 100644 --- a/maven-release-plugin/src/it/projects/prepare/fail-on-snapshots/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/fail-on-snapshots/verify.groovy @@ -20,13 +20,19 @@ def buildLog = new File(basedir,'build.log') def nonReleased = buildLog.readLines() - .dropWhile{ !it.endsWith("Can't release project due to non released dependencies :") } - .drop(1) - .collect{ (it - '[ERROR]').trim() } - .takeWhile{ !it.startsWith("in project 'fail-on-snapshot'") } as Set + .dropWhile{ + !it.endsWith("Can't release project due to non released dependencies :") + } + .drop(1) + .collect{ (it - '[ERROR]').trim() } + .takeWhile{ + !it.startsWith("in project 'fail-on-snapshot'") + } as Set -assert nonReleased == ['test:dependency:jar:1.0-SNAPSHOT:compile', - 'test:dependency.test:jar:1.0-SNAPSHOT:test', - 'test:extension:jar:1.0-SNAPSHOT', - 'test:plugin:maven-plugin:1.0-SNAPSHOT:runtime', - 'test:report:maven-plugin:1.0-SNAPSHOT:runtime'] as Set \ No newline at end of file +assert nonReleased == [ + 'test:dependency:jar:1.0-SNAPSHOT:compile', + 'test:dependency.test:jar:1.0-SNAPSHOT:test', + 'test:extension:jar:1.0-SNAPSHOT', + 'test:plugin:maven-plugin:1.0-SNAPSHOT:runtime', + 'test:report:maven-plugin:1.0-SNAPSHOT:runtime' +] as Set \ No newline at end of file diff --git a/maven-release-plugin/src/it/projects/prepare/flat-multi-module/parent-project/verify.groovy b/maven-release-plugin/src/it/projects/prepare/flat-multi-module/parent-project/verify.groovy index 0064cc77..b3c660fd 100644 --- a/maven-release-plugin/src/it/projects/prepare/flat-multi-module/parent-project/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/flat-multi-module/parent-project/verify.groovy @@ -17,7 +17,7 @@ * under the License. */ -File buildLog = new File( basedir, "build.log" ) +File buildLog = new File(basedir, "build.log") println "Checking logs.." @@ -26,6 +26,6 @@ String contents = buildLog.getText() String expected1 = "Full run would tag working copy '" + basedir.getParentFile() + "'" boolean found = (contents.contains(expected1) && contents.contains(" with label 'parent-project-1.0'")) || - contents.contains("module-b with label 'module-b-1.0'") || - contents.contains("module-a with label 'module-a-1.0'") + contents.contains("module-b with label 'module-b-1.0'") || + contents.contains("module-a with label 'module-a-1.0'") assert found : "No expected tag label found in build.log" diff --git a/maven-release-plugin/src/it/projects/prepare/gh-1420/verify.groovy b/maven-release-plugin/src/it/projects/prepare/gh-1420/verify.groovy index 66ac2982..5394990a 100644 --- a/maven-release-plugin/src/it/projects/prepare/gh-1420/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/gh-1420/verify.groovy @@ -19,26 +19,26 @@ import groovy.xml.XmlSlurper -def pom = new XmlSlurper().parse( new File( basedir, 'pom.xml.tag' ) ) +def pom = new XmlSlurper().parse(new File(basedir, 'pom.xml.tag')) assert pom.scm.tag.text() == 'gh-1420-1.0' assert pom.version.text() == '1.0' -def pomNext = new XmlSlurper().parse( new File( basedir, 'pom.xml.next' ) ) +def pomNext = new XmlSlurper().parse(new File(basedir, 'pom.xml.next')) assert pomNext.scm.tag.text() == 'HEAD' assert pomNext.version.text() == '1.1-SNAPSHOT' -def pom1 = new XmlSlurper().parse( new File( basedir, 'module1/pom.xml.tag' ) ) +def pom1 = new XmlSlurper().parse(new File(basedir, 'module1/pom.xml.tag')) assert pom1.scm.size() == 0 assert pom1.parent.version.text() == '1.0' -def pom1Next = new XmlSlurper().parse( new File( basedir, 'module1/pom.xml.next' ) ) +def pom1Next = new XmlSlurper().parse(new File(basedir, 'module1/pom.xml.next')) assert pom1Next.scm.size() == 0 assert pom1Next.parent.version.text() == '1.1-SNAPSHOT' -def pom2 = new XmlSlurper().parse( new File( basedir, 'module1/module2/pom.xml.tag' ) ) +def pom2 = new XmlSlurper().parse(new File(basedir, 'module1/module2/pom.xml.tag')) assert pom2.scm.size() == 0 assert pom2.parent.version.text() == '1.0' -def pom2Next = new XmlSlurper().parse( new File( basedir, 'module1/module2/pom.xml.next' ) ) +def pom2Next = new XmlSlurper().parse(new File(basedir, 'module1/module2/pom.xml.next')) assert pom2Next.scm.size() == 0 assert pom2Next.parent.version.text() == '1.1-SNAPSHOT' diff --git a/maven-release-plugin/src/it/projects/prepare/namespace/verify.groovy b/maven-release-plugin/src/it/projects/prepare/namespace/verify.groovy index b7aff067..253170e5 100644 --- a/maven-release-plugin/src/it/projects/prepare/namespace/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/namespace/verify.groovy @@ -19,13 +19,13 @@ import groovy.xml.XmlSlurper -def project = new XmlSlurper().parse( new File( basedir, "pom.xml" ) ) +def project = new XmlSlurper().parse(new File(basedir, "pom.xml")) assert project['@xsi:schemaLocation'] == "http://maven.apache.org/POM/4.0.0 https://maven.apache.org/maven-v4_0_0.xsd" -def projectTag = new XmlSlurper().parse( new File( basedir, "pom.xml.tag" ) ) +def projectTag = new XmlSlurper().parse(new File(basedir, "pom.xml.tag")) assert projectTag['@xsi:schemaLocation'] == "http://maven.apache.org/POM/4.0.0 https://maven.apache.org/maven-v4_0_0.xsd" -def projectNext = new XmlSlurper().parse( new File( basedir, "pom.xml.next" ) ) +def projectNext = new XmlSlurper().parse(new File(basedir, "pom.xml.next")) assert projectNext['@xsi:schemaLocation'] == "http://maven.apache.org/POM/4.0.0 https://maven.apache.org/maven-v4_0_0.xsd" return true diff --git a/maven-release-plugin/src/it/projects/prepare/version-policy/verify.groovy b/maven-release-plugin/src/it/projects/prepare/version-policy/verify.groovy index f80703a5..ef50e169 100644 --- a/maven-release-plugin/src/it/projects/prepare/version-policy/verify.groovy +++ b/maven-release-plugin/src/it/projects/prepare/version-policy/verify.groovy @@ -19,7 +19,7 @@ import groovy.xml.XmlSlurper -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() assert 1 == buildLog.getText().count("[INPUT:Version] #0.1.2-SNAPSHOT#") @@ -45,16 +45,16 @@ assert 1 == buildLog.getText().count("[INPUT:Changeset[17].comment] #Commit 2#" assert 1 == buildLog.getText().count("[INPUT:Changeset[17].tag] #v1.2.3#") // The pom based version is NOT related to what the actual version will be. -File pomXml = new File( basedir, 'pom.xml' ) +File pomXml = new File(basedir, 'pom.xml') assert pomXml.exists() -assert new XmlSlurper().parse( pomXml ).version.text() == "0.1.2-SNAPSHOT" +assert new XmlSlurper().parse(pomXml).version.text() == "0.1.2-SNAPSHOT" // The actual version is hard coded -File pomXmlTag = new File( basedir, 'pom.xml.tag' ) +File pomXmlTag = new File(basedir, 'pom.xml.tag') assert pomXmlTag.exists() -assert new XmlSlurper().parse( pomXmlTag ).version.text() == "1.2.3" +assert new XmlSlurper().parse(pomXmlTag).version.text() == "1.2.3" // The next development version is hard coded -File pomXmlNext = new File( basedir, 'pom.xml.next' ) +File pomXmlNext = new File(basedir, 'pom.xml.next') assert pomXmlNext.exists() -assert new XmlSlurper().parse( pomXmlNext ).version.text() == "4.5.6-SNAPSHOT" +assert new XmlSlurper().parse(pomXmlNext).version.text() == "4.5.6-SNAPSHOT" diff --git a/maven-release-plugin/src/it/projects/stage/MRELEASE-1104-both-parameters/verify.groovy b/maven-release-plugin/src/it/projects/stage/MRELEASE-1104-both-parameters/verify.groovy index d0950f13..3b74e09a 100644 --- a/maven-release-plugin/src/it/projects/stage/MRELEASE-1104-both-parameters/verify.groovy +++ b/maven-release-plugin/src/it/projects/stage/MRELEASE-1104-both-parameters/verify.groovy @@ -17,10 +17,10 @@ * under the License. */ -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() -assert buildLog.text.contains( "with additional arguments: -DskipTests -DaltDeploymentRepository=\"file://" ) +assert buildLog.text.contains("with additional arguments: -DskipTests -DaltDeploymentRepository=\"file://") diff --git a/maven-release-plugin/src/it/projects/stage/MRELEASE-1104-stage-repo-only/verify.groovy b/maven-release-plugin/src/it/projects/stage/MRELEASE-1104-stage-repo-only/verify.groovy index 930fef4a..c9db9e86 100644 --- a/maven-release-plugin/src/it/projects/stage/MRELEASE-1104-stage-repo-only/verify.groovy +++ b/maven-release-plugin/src/it/projects/stage/MRELEASE-1104-stage-repo-only/verify.groovy @@ -17,10 +17,10 @@ * under the License. */ -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() -assert buildLog.text.contains( "with additional arguments: -DaltDeploymentRepository=\"file://" ) +assert buildLog.text.contains("with additional arguments: -DaltDeploymentRepository=\"file://") diff --git a/maven-release-plugin/src/it/projects/update-versions/MRELEASE-555/verify.groovy b/maven-release-plugin/src/it/projects/update-versions/MRELEASE-555/verify.groovy index e1a034c0..66be998d 100644 --- a/maven-release-plugin/src/it/projects/update-versions/MRELEASE-555/verify.groovy +++ b/maven-release-plugin/src/it/projects/update-versions/MRELEASE-555/verify.groovy @@ -20,11 +20,11 @@ import groovy.xml.XmlSlurper -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() -def projectRoot = new XmlSlurper().parse( new File( basedir, "module-b/pom.xml" ) ) +def projectRoot = new XmlSlurper().parse(new File(basedir, "module-b/pom.xml")) -assert projectRoot.dependencies.dependency.version.text() == "1.1-SNAPSHOT" +assert projectRoot.dependencies.dependency.version.text() == "1.1-SNAPSHOT" return true \ No newline at end of file diff --git a/maven-release-plugin/src/it/projects/update-versions/MRELEASE-611/verify.groovy b/maven-release-plugin/src/it/projects/update-versions/MRELEASE-611/verify.groovy index 46b1bd0d..24b9906a 100644 --- a/maven-release-plugin/src/it/projects/update-versions/MRELEASE-611/verify.groovy +++ b/maven-release-plugin/src/it/projects/update-versions/MRELEASE-611/verify.groovy @@ -20,11 +20,11 @@ import groovy.xml.XmlSlurper -File buildLog = new File( basedir, 'build.log' ) +File buildLog = new File(basedir, 'build.log') assert buildLog.exists() -def projectRoot = new XmlSlurper().parse( new File( basedir, "pom.xml" ) ) +def projectRoot = new XmlSlurper().parse(new File(basedir, "pom.xml")) -assert projectRoot.version.text() == "1.1-SNAPSHOT" +assert projectRoot.version.text() == "1.1-SNAPSHOT" return true \ No newline at end of file diff --git a/maven-release-plugin/src/it/projects/update-versions/MRELEASE-976/verify.groovy b/maven-release-plugin/src/it/projects/update-versions/MRELEASE-976/verify.groovy index 7691e43d..bf4a69f2 100644 --- a/maven-release-plugin/src/it/projects/update-versions/MRELEASE-976/verify.groovy +++ b/maven-release-plugin/src/it/projects/update-versions/MRELEASE-976/verify.groovy @@ -21,7 +21,7 @@ import groovy.xml.XmlSlurper // verifies that the version is unchanged because of the custom policy: 1.0-SNAPSHOT -> 1.0 -> 1.0-SNAPSHOT -def project = new XmlSlurper().parse( new File( basedir, "pom.xml" ) ) +def project = new XmlSlurper().parse(new File(basedir, "pom.xml")) assert project.version.text() == "1.0-SNAPSHOT" return true
