Browse Source

RedirectorElementTest stopped working on windows w/h cat on the path.

Now it passes the testcase if cat is not available.


git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@277743 13f79535-47bb-0310-9956-ffa450edef68
master
Jacobus Martinus Kruithof 20 years ago
parent
commit
782bc21332
2 changed files with 6 additions and 1 deletions
  1. +3
    -0
      src/etc/testcases/types/redirector.xml
  2. +3
    -1
      src/testcases/org/apache/tools/ant/types/RedirectorElementTest.java

+ 3
- 0
src/etc/testcases/types/redirector.xml View File

@@ -22,6 +22,9 @@
</target>

<target name="testLogInputString" depends="cat-check" if="can-cat">
<echo>
testLogInputString can-cat
</echo>
<exec executable="cat">
<redirector inputstring="foo" loginputstring="false" />
</exec>


+ 3
- 1
src/testcases/org/apache/tools/ant/types/RedirectorElementTest.java View File

@@ -51,6 +51,8 @@ public class RedirectorElementTest extends BuildFileTest {

public void testLogInputString() {
executeTarget("testLogInputString");
assertDebuglogContaining("Using input string");
if (super.getLog().indexOf("testLogInputString can-cat") >=0 ) {
assertDebuglogContaining("Using input string");
}
}
}

Loading…
Cancel
Save