maven-surefire-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From car...@apache.org
Subject svn commit: r395152 - in /maven/surefire/trunk/surefire-booter/src: main/java/org/apache/maven/surefire/SurefireBooter.java test/java/org/apache/maven/surefire/SurefireBooterTest.java
Date Wed, 19 Apr 2006 06:25:10 GMT
Author: carlos
Date: Tue Apr 18 23:25:06 2006
New Revision: 395152

URL: http://svn.apache.org/viewcvs?rev=395152&view=rev
Log:
[MSUREFIRE-86] Make surefire compile under Java 1.3

Modified:
    maven/surefire/trunk/surefire-booter/src/main/java/org/apache/maven/surefire/SurefireBooter.java
    maven/surefire/trunk/surefire-booter/src/test/java/org/apache/maven/surefire/SurefireBooterTest.java

Modified: maven/surefire/trunk/surefire-booter/src/main/java/org/apache/maven/surefire/SurefireBooter.java
URL: http://svn.apache.org/viewcvs/maven/surefire/trunk/surefire-booter/src/main/java/org/apache/maven/surefire/SurefireBooter.java?rev=395152&r1=395151&r2=395152&view=diff
==============================================================================
--- maven/surefire/trunk/surefire-booter/src/main/java/org/apache/maven/surefire/SurefireBooter.java
(original)
+++ maven/surefire/trunk/surefire-booter/src/main/java/org/apache/maven/surefire/SurefireBooter.java
Tue Apr 18 23:25:06 2006
@@ -835,11 +835,16 @@
      * 
      * @since 1.5.4
      * @param s the string to be splitted
-     * @param delim the delimiter to be used
+     * @param delimiter the delimiter to be used
      * @return an array with the Strings between the delimiters
      */
-    public static String[] split( String s, String delim )
+    public static String[] split( String s, String delimiter )
     {
+        String delim = delimiter;
+        if ( "\\|".equals( delimiter ) )
+        {
+            delim = "|";
+        }
         if ( s.equals(delim) )
         {
             return new String[0];

Modified: maven/surefire/trunk/surefire-booter/src/test/java/org/apache/maven/surefire/SurefireBooterTest.java
URL: http://svn.apache.org/viewcvs/maven/surefire/trunk/surefire-booter/src/test/java/org/apache/maven/surefire/SurefireBooterTest.java?rev=395152&r1=395151&r2=395152&view=diff
==============================================================================
--- maven/surefire/trunk/surefire-booter/src/test/java/org/apache/maven/surefire/SurefireBooterTest.java
(original)
+++ maven/surefire/trunk/surefire-booter/src/test/java/org/apache/maven/surefire/SurefireBooterTest.java
Tue Apr 18 23:25:06 2006
@@ -37,58 +37,58 @@
         s = "x1:y2:z;j:f";
         List list = Arrays.asList( SurefireBooter.split( s, d ) );
         assertEquals( Arrays.asList( new String[] { "x1", "y2", "z;j", "f" } ), list );
-        assertEquals( Arrays.asList( s.split( d ) ), list );
+        //assertEquals( Arrays.asList( s.split( d ) ), list );
 
         s = "x1";
         list = Arrays.asList( SurefireBooter.split( s, d ) );
         assertEquals( Arrays.asList( new String[] { "x1" } ), list );
-        assertEquals( Arrays.asList( s.split( d ) ), list );
+        //assertEquals( Arrays.asList( s.split( d ) ), list );
 
         s = "x1:";
         list = Arrays.asList( SurefireBooter.split( s, d ) );
         assertEquals( Arrays.asList( new String[] { "x1" } ), list );
-        assertEquals( Arrays.asList( s.split( d ) ), list );
+        //assertEquals( Arrays.asList( s.split( d ) ), list );
 
         s = "";
         list = Arrays.asList( SurefireBooter.split( s, d ) );
         assertEquals( Arrays.asList( new String[] { "" } ), list );
-        assertEquals( Arrays.asList( s.split( d ) ), list );
+        //assertEquals( Arrays.asList( s.split( d ) ), list );
 
         s = ":";
         list = Arrays.asList( SurefireBooter.split( s, d ) );
         assertEquals( Collections.EMPTY_LIST, list );
-        assertEquals( Arrays.asList( s.split( d ) ), list );
+        //assertEquals( Arrays.asList( s.split( d ) ), list );
 
         d = "::";
         s = "x1::y2::z;j::f";
         list = Arrays.asList( SurefireBooter.split( s, d ) );
         assertEquals( Arrays.asList( new String[] { "x1", "y2", "z;j", "f" } ), list );
-        assertEquals( Arrays.asList( s.split( d ) ), list );
+        //assertEquals( Arrays.asList( s.split( d ) ), list );
 
         s = "x1";
         list = Arrays.asList( SurefireBooter.split( s, d ) );
         assertEquals( Arrays.asList( new String[] { "x1" } ), list );
-        assertEquals( Arrays.asList( s.split( d ) ), list );
+        //assertEquals( Arrays.asList( s.split( d ) ), list );
 
         s = "x1::";
         list = Arrays.asList( SurefireBooter.split( s, d ) );
         assertEquals( Arrays.asList( new String[] { "x1" } ), list );
-        assertEquals( Arrays.asList( s.split( d ) ), list );
+        //assertEquals( Arrays.asList( s.split( d ) ), list );
 
         s = "";
         list = Arrays.asList( SurefireBooter.split( s, d ) );
         assertEquals( Arrays.asList( new String[] { "" } ), list );
-        assertEquals( Arrays.asList( s.split( d ) ), list );
+        //assertEquals( Arrays.asList( s.split( d ) ), list );
 
         s = ":";
         list = Arrays.asList( SurefireBooter.split( s, d ) );
         assertEquals( Arrays.asList( new String[] { ":" } ), list );
-        assertEquals( Arrays.asList( s.split( d ) ), list );
+        //assertEquals( Arrays.asList( s.split( d ) ), list );
 
         s = "::";
         list = Arrays.asList( SurefireBooter.split( s, d ) );
         assertEquals( Collections.EMPTY_LIST, list );
-        assertEquals( Arrays.asList( s.split( d ) ), list );
+        //assertEquals( Arrays.asList( s.split( d ) ), list );
     }
 
 }



Mime
View raw message