You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by be...@apache.org on 2008/09/21 14:59:54 UTC

svn commit: r697502 - /maven/core-integration-testing/trunk/core-integration-tests-support/maven-integration-test-helper/src/main/java/org/apache/maven/integrationtests/AbstractMavenIntegrationTestCase.java

Author: bentmann
Date: Sun Sep 21 05:59:53 2008
New Revision: 697502

URL: http://svn.apache.org/viewvc?rev=697502&view=rev
Log:
o Decoupled subclasses from maven-artifact

Modified:
    maven/core-integration-testing/trunk/core-integration-tests-support/maven-integration-test-helper/src/main/java/org/apache/maven/integrationtests/AbstractMavenIntegrationTestCase.java

Modified: maven/core-integration-testing/trunk/core-integration-tests-support/maven-integration-test-helper/src/main/java/org/apache/maven/integrationtests/AbstractMavenIntegrationTestCase.java
URL: http://svn.apache.org/viewvc/maven/core-integration-testing/trunk/core-integration-tests-support/maven-integration-test-helper/src/main/java/org/apache/maven/integrationtests/AbstractMavenIntegrationTestCase.java?rev=697502&r1=697501&r2=697502&view=diff
==============================================================================
--- maven/core-integration-testing/trunk/core-integration-tests-support/maven-integration-test-helper/src/main/java/org/apache/maven/integrationtests/AbstractMavenIntegrationTestCase.java (original)
+++ maven/core-integration-testing/trunk/core-integration-tests-support/maven-integration-test-helper/src/main/java/org/apache/maven/integrationtests/AbstractMavenIntegrationTestCase.java Sun Sep 21 05:59:53 2008
@@ -53,9 +53,15 @@
     }
 
     protected AbstractMavenIntegrationTestCase( String versionRangeStr )
-        throws InvalidVersionSpecificationException
     {
-        versionRange = VersionRange.createFromVersionSpec( versionRangeStr );
+        try
+        {
+            versionRange = VersionRange.createFromVersionSpec( versionRangeStr );
+        }
+        catch ( InvalidVersionSpecificationException e)
+        {
+            throw (RuntimeException) new IllegalArgumentException( "Invalid version range: " + versionRangeStr ).initCause( e );
+        }
 
         String v = System.getProperty( "maven.version" );
         if ( v != null )
@@ -79,9 +85,15 @@
      * executing altogether if the wrong version is present.
      */
     protected boolean matchesVersionRange( String versionRangeStr )
-        throws InvalidVersionSpecificationException
     {
-        versionRange = VersionRange.createFromVersionSpec( versionRangeStr );
+        try
+        {
+            versionRange = VersionRange.createFromVersionSpec( versionRangeStr );
+        }
+        catch ( InvalidVersionSpecificationException e)
+        {
+            throw (RuntimeException) new IllegalArgumentException( "Invalid version range: " + versionRangeStr ).initCause( e );
+        }
 
         String v = System.getProperty( "maven.version" );
         if ( v != null )