Author: sgoeschl
Date: Tue Sep 14 20:23:58 2010
New Revision: 997077
URL: http://svn.apache.org/viewvc?rev=997077&view=rev
Log:
Don't use CommandLine.toString() because it does its own quoting and would
confuse users assuming that this represents the exact command line
Modified:
commons/proper/exec/trunk/src/test/java/org/apache/commons/exec/CommandLineTest.java
Modified:
commons/proper/exec/trunk/src/test/java/org/apache/commons/exec/CommandLineTest.java
URL:
http://svn.apache.org/viewvc/commons/proper/exec/trunk/src/test/java/org/apache/commons/exec/CommandLineTest.java?rev=997077&r1=997076&r2=997077&view=diff
==============================================================================
---
commons/proper/exec/trunk/src/test/java/org/apache/commons/exec/CommandLineTest.java
(original)
+++
commons/proper/exec/trunk/src/test/java/org/apache/commons/exec/CommandLineTest.java
Tue Sep 14 20:23:58 2010
@@ -287,7 +287,6 @@ public class CommandLineTest extends Tes
cmdl.addArgument("30", false);
cmdl.addArgument("-XX:+UseParallelGC", false);
cmdl.addArgument("\"-XX:ParallelGCThreads=2\"", false);
- assertEquals("runMemorySud.cmd 10 30 -XX:+UseParallelGC
\"-XX:ParallelGCThreads=2\"", cmdl.toString());
assertEquals(new String[] {"runMemorySud.cmd", "10", "30",
"-XX:+UseParallelGC", "\"-XX:ParallelGCThreads=2\""}, cmdl.toStrings());
}
@@ -298,7 +297,6 @@ public class CommandLineTest extends Tes
public void testComplexAddArguments1() {
CommandLine cmdl = new CommandLine("runMemorySud.cmd");
cmdl.addArguments(new String[] {"10", "30", "-XX:+UseParallelGC",
"\"-XX:ParallelGCThreads=2\""}, false);
- assertEquals("runMemorySud.cmd 10 30 -XX:+UseParallelGC
\"-XX:ParallelGCThreads=2\"", cmdl.toString());
assertEquals(new String[] {"runMemorySud.cmd", "10", "30",
"-XX:+UseParallelGC", "\"-XX:ParallelGCThreads=2\""}, cmdl.toStrings());
}
@@ -311,7 +309,6 @@ public class CommandLineTest extends Tes
public void testComplexAddArguments2() {
CommandLine cmdl = new CommandLine("runMemorySud.cmd");
cmdl.addArguments("10 30 -XX:+UseParallelGC
'\"-XX:ParallelGCThreads=2\"'", false);
- assertEquals("runMemorySud.cmd 10 30 -XX:+UseParallelGC
\"-XX:ParallelGCThreads=2\"", cmdl.toString());
assertEquals(new String[] {"runMemorySud.cmd", "10", "30",
"-XX:+UseParallelGC", "\"-XX:ParallelGCThreads=2\""}, cmdl.toStrings());
}