ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bode...@apache.org
Subject svn commit: r791400 - /ant/core/trunk/src/tests/junit/org/apache/tools/ant/types/CommandlineTest.java
Date Mon, 06 Jul 2009 07:51:00 GMT
Author: bodewig
Date: Mon Jul  6 07:50:59 2009
New Revision: 791400

URL: http://svn.apache.org/viewvc?rev=791400&view=rev
Log:
additional tests for new prefix/suffic attributes of command line args.  PR 47365.  Submitted
by Martin von Gagern

Modified:
    ant/core/trunk/src/tests/junit/org/apache/tools/ant/types/CommandlineTest.java

Modified: ant/core/trunk/src/tests/junit/org/apache/tools/ant/types/CommandlineTest.java
URL: http://svn.apache.org/viewvc/ant/core/trunk/src/tests/junit/org/apache/tools/ant/types/CommandlineTest.java?rev=791400&r1=791399&r2=791400&view=diff
==============================================================================
--- ant/core/trunk/src/tests/junit/org/apache/tools/ant/types/CommandlineTest.java (original)
+++ ant/core/trunk/src/tests/junit/org/apache/tools/ant/types/CommandlineTest.java Mon Jul
 6 07:50:59 2009
@@ -160,4 +160,16 @@
         assertEquals(1, s.length);
         assertEquals("foo,1", s[0]);
     }
+
+    public void testPrefixSuffixLine() {
+        Commandline c = new Commandline();
+        Commandline.Argument a = c.createArgument();
+        a.setLine("one two");
+        a.setPrefix("number ");
+        a.setSuffix(".");
+        String[] s = c.getCommandline();
+        assertEquals(2, s.length);
+        assertEquals("number one.", s[0]);
+        assertEquals("number two.", s[1]);
+    }
 }



Mime
View raw message