maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rfscho...@apache.org
Subject [maven-release] 01/02: Cleanup tests
Date Fri, 23 Mar 2018 22:08:35 GMT
This is an automated email from the ASF dual-hosted git repository.

rfscholte pushed a commit to branch Paths
in repository https://gitbox.apache.org/repos/asf/maven-release.git

commit bb417d5ed79ba198db059bdb08ae878019d59cbb
Author: rfscholte <rfscholte@apache.org>
AuthorDate: Fri Mar 23 22:27:20 2018 +0100

    Cleanup tests
---
 .../phase/AbstractEditModeRewritingReleasePhaseTestCase.java      | 6 ++++--
 .../release/phase/AbstractRewritingReleasePhaseTestCase.java      | 2 --
 .../maven/shared/release/phase/RewritePomsForBranchPhaseTest.java | 8 ++++----
 .../shared/release/phase/RewritePomsForDevelopmentPhaseTest.java  | 2 +-
 .../shared/release/phase/RewritePomsForReleasePhaseTest.java      | 8 ++++----
 5 files changed, 13 insertions(+), 13 deletions(-)

diff --git a/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/AbstractEditModeRewritingReleasePhaseTestCase.java
b/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/AbstractEditModeRewritingReleasePhaseTestCase.java
index 040f98d..03141b2 100644
--- a/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/AbstractEditModeRewritingReleasePhaseTestCase.java
+++ b/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/AbstractEditModeRewritingReleasePhaseTestCase.java
@@ -82,7 +82,8 @@ public abstract class AbstractEditModeRewritingReleasePhaseTestCase
         throws Exception
     {
         List<MavenProject> reactorProjects = createReactorProjects( "basic-pom" );
-        ReleaseDescriptorBuilder builder = createDescriptorFromBasicPom( reactorProjects
);
+        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects
);
+        builder.setWorkingDirectory( getWorkingDirectory( "basic-pom" ).toString() );
         builder.setScmUseEditMode( true );
         mapNextVersion( builder, "groupId:artifactId" );
 
@@ -112,7 +113,8 @@ public abstract class AbstractEditModeRewritingReleasePhaseTestCase
     {
         // prepare
         List<MavenProject> reactorProjects = createReactorProjects( "basic-pom" );
-        ReleaseDescriptorBuilder builder = createDescriptorFromBasicPom( reactorProjects
);
+        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects
);
+        builder.setWorkingDirectory( getWorkingDirectory( "basic-pom" ).toString() );
         builder.setScmUseEditMode( true );
         mapNextVersion( builder, "groupId:artifactId" );
 
diff --git a/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/AbstractRewritingReleasePhaseTestCase.java
b/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/AbstractRewritingReleasePhaseTestCase.java
index 0e2b10b..290550e 100644
--- a/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/AbstractRewritingReleasePhaseTestCase.java
+++ b/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/AbstractRewritingReleasePhaseTestCase.java
@@ -769,8 +769,6 @@ public abstract class AbstractRewritingReleasePhaseTestCase
             builder.setScmSourceUrl( rootProject.getScm().getConnection() );
         }
 
-        builder.setWorkingDirectory( getTestFile( "target/test/checkout" ).getAbsolutePath()
);
-
         return builder;
     }
 }
diff --git a/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/RewritePomsForBranchPhaseTest.java
b/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/RewritePomsForBranchPhaseTest.java
index 9840d3e..a560d68 100644
--- a/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/RewritePomsForBranchPhaseTest.java
+++ b/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/RewritePomsForBranchPhaseTest.java
@@ -127,7 +127,7 @@ public class RewritePomsForBranchPhaseTest
         throws Exception
     {
         List<MavenProject> reactorProjects = createReactorProjects( "basic-pom" );
-        ReleaseDescriptorBuilder builder = createDescriptorFromBasicPom( reactorProjects
);
+        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects,
"basic-pom" );
         builder.addReleaseVersion( "groupId:artifactId", NEXT_VERSION );
 
         File testFile = getTestFile( "target/test-classes/projects/rewrite-for-branch/basic-pom/pom.xml.branch"
);
@@ -221,7 +221,7 @@ public class RewritePomsForBranchPhaseTest
     {
 
         List<MavenProject> reactorProjects = createReactorProjects( "basic-pom-with-cvs"
);
-        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects
);
+        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects,
"basic-pom-with-cvs" );
         mapNextVersion( builder, "groupId:artifactId" );
 
         phase.execute( ReleaseUtils.buildReleaseDescriptor( builder ), new DefaultReleaseEnvironment(),
reactorProjects );
@@ -277,7 +277,7 @@ public class RewritePomsForBranchPhaseTest
         throws Exception
     {
         List<MavenProject> reactorProjects = createReactorProjects( "basic-pom-with-cvs-from-tag"
);
-        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects
);
+        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects,
"basic-pom-with-cvs-from-tag" );
         mapNextVersion( builder, "groupId:artifactId" );
 
         phase.execute( ReleaseUtils.buildReleaseDescriptor( builder ), new DefaultReleaseEnvironment(),
reactorProjects );
@@ -315,7 +315,7 @@ public class RewritePomsForBranchPhaseTest
         throws Exception
     {
         List<MavenProject> reactorProjects = createReactorProjects( "interpolated-versions"
);
-        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects
);
+        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects,
"interpolated-versions" );
 
         builder.addReleaseVersion( "groupId:artifactId", NEXT_VERSION );
         builder.addReleaseVersion( "groupId:subproject1", ALTERNATIVE_NEXT_VERSION );
diff --git a/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/RewritePomsForDevelopmentPhaseTest.java
b/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/RewritePomsForDevelopmentPhaseTest.java
index 17d46bc..3a8d32a 100644
--- a/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/RewritePomsForDevelopmentPhaseTest.java
+++ b/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/RewritePomsForDevelopmentPhaseTest.java
@@ -185,7 +185,7 @@ public class RewritePomsForDevelopmentPhaseTest
     protected ReleaseDescriptorBuilder createDescriptorFromBasicPom( List<MavenProject>
reactorProjects )
         throws Exception
     {
-        ReleaseDescriptorBuilder builder = super.createDescriptorFromBasicPom( reactorProjects
);
+        ReleaseDescriptorBuilder builder = super.createDescriptorFromProjects( reactorProjects
);
 
         mapScm( builder );
 
diff --git a/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/RewritePomsForReleasePhaseTest.java
b/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/RewritePomsForReleasePhaseTest.java
index 8c7d01c..ac74644 100644
--- a/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/RewritePomsForReleasePhaseTest.java
+++ b/maven-release-manager/src/test/java/org/apache/maven/shared/release/phase/RewritePomsForReleasePhaseTest.java
@@ -129,7 +129,7 @@ public class RewritePomsForReleasePhaseTest
         throws Exception
     {
         List<MavenProject> reactorProjects = createReactorProjects( "basic-pom" );
-        ReleaseDescriptorBuilder builder = createDescriptorFromBasicPom( reactorProjects
);
+        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects,
"basic-pom" );
         builder.addReleaseVersion( "groupId:artifactId", NEXT_VERSION );
 
         File testFile = getTestFile( "target/test-classes/projects/rewrite-for-release/basic-pom/pom.xml.tag"
);
@@ -221,7 +221,7 @@ public class RewritePomsForReleasePhaseTest
     {
 
         List<MavenProject> reactorProjects = createReactorProjects( "basic-pom-with-cvs"
);
-        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects
);
+        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects,
"basic-pom-with-cvs" );
         mapNextVersion( builder, "groupId:artifactId" );
 
         phase.execute( ReleaseUtils.buildReleaseDescriptor( builder ), new DefaultReleaseEnvironment(),
reactorProjects );
@@ -277,7 +277,7 @@ public class RewritePomsForReleasePhaseTest
         throws Exception
     {
         List<MavenProject> reactorProjects = createReactorProjects( "basic-pom-with-cvs-from-tag"
);
-        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects
);
+        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects,
"basic-pom-with-cvs-from-tag" );
         mapNextVersion( builder, "groupId:artifactId" );
 
         phase.execute( ReleaseUtils.buildReleaseDescriptor( builder ), new DefaultReleaseEnvironment(),
reactorProjects );
@@ -315,7 +315,7 @@ public class RewritePomsForReleasePhaseTest
         throws Exception
     {
         List<MavenProject> reactorProjects = createReactorProjects( "interpolated-versions"
);
-        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects
);
+        ReleaseDescriptorBuilder builder = createDescriptorFromProjects( reactorProjects,
"interpolated-versions" );
 
         builder.addReleaseVersion( "groupId:artifactId", NEXT_VERSION );
         builder.addReleaseVersion( "groupId:subproject1", ALTERNATIVE_NEXT_VERSION );

-- 
To stop receiving notification emails like this one, please contact
rfscholte@apache.org.

Mime
View raw message