maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rfscho...@apache.org
Subject svn commit: r1395380 - /maven/shared/trunk/maven-shared-utils/src/test/java/org/apache/maven/shared/utils/PathToolTest.java
Date Sun, 07 Oct 2012 20:38:17 GMT
Author: rfscholte
Date: Sun Oct  7 20:38:16 2012
New Revision: 1395380

URL: http://svn.apache.org/viewvc?rev=1395380&view=rev
Log:
Make PathToolTest OS-specific, some path-resolving methods won't work everywhere

Modified:
    maven/shared/trunk/maven-shared-utils/src/test/java/org/apache/maven/shared/utils/PathToolTest.java

Modified: maven/shared/trunk/maven-shared-utils/src/test/java/org/apache/maven/shared/utils/PathToolTest.java
URL: http://svn.apache.org/viewvc/maven/shared/trunk/maven-shared-utils/src/test/java/org/apache/maven/shared/utils/PathToolTest.java?rev=1395380&r1=1395379&r2=1395380&view=diff
==============================================================================
--- maven/shared/trunk/maven-shared-utils/src/test/java/org/apache/maven/shared/utils/PathToolTest.java
(original)
+++ maven/shared/trunk/maven-shared-utils/src/test/java/org/apache/maven/shared/utils/PathToolTest.java
Sun Oct  7 20:38:16 2012
@@ -20,6 +20,7 @@ package org.apache.maven.shared.utils;
  */
 
 import org.hamcrest.CoreMatchers;
+import org.junit.Assume;
 import org.junit.Rule;
 import org.junit.Test;
 import org.junit.Assert;
@@ -82,6 +83,8 @@ public class PathToolTest extends Assert
     // Keep in sync with testGetRelativeFilePath_Windows()
     public void testGetRelativeFilePath_NonWindows()
     {
+        Assume.assumeThat( File.separatorChar, is( '/' ) );
+
         assertThat( PathTool.getRelativeFilePath( null, null )
                   , is( "" ) );
 
@@ -117,6 +120,8 @@ public class PathToolTest extends Assert
     // Keep in sync with testGetRelativeFilePath_NonWindows()
     public void testGetRelativeFilePath_Windows()
     {
+        Assume.assumeThat( File.separatorChar, is( '\\' ) );
+
         assertThat( PathTool.getRelativeFilePath( null, null )
                   , is( "" ) );
 



Mime
View raw message