Browse Source

disallow mixing of old-style "testcase" property with either of antunit.testcase, junit.testcase, or both. Additionally, allow files simply named test.xml in addition to *-test.xml .

git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@449091 13f79535-47bb-0310-9956-ffa450edef68
master
Matthew Jason Benson 19 years ago
parent
commit
edad691d59
1 changed files with 27 additions and 1 deletions
  1. +27
    -1
      build.xml

+ 27
- 1
build.xml View File

@@ -1592,6 +1592,18 @@
</sequential>
</macrodef>

<fail>"testcase" cannot be specified with "junit.testcase" or "antunit.testcase".
<condition>
<and>
<isset property="testcase" />
<or>
<isset property="antunit.testcase" />
<isset property="junit.testcase" />
</or>
</and>
</condition>
</fail>

<condition property="antunit.testcase" value="${testcase}">
<available file="${src.antunit}/${testcase}" />
</condition>
@@ -1600,6 +1612,20 @@
<available classname="${testcase}" classpathref="tests-classpath" />
</condition>

<fail>Cannot locate test ${testcase}
<condition>
<and>
<isset property="testcase" />
<not>
<or>
<isset property="antunit.testcase" />
<isset property="junit.testcase" />
</or>
</not>
</and>
</condition>
</fail>

<condition property="run.junit">
<and>
<not><equals arg1="${testcase}" arg2="${antunit.testcase}" /></not>
@@ -1830,7 +1856,7 @@
if="run.antunit">

<condition property="antunit.includes" value="${antunit.testcase}"
else="**/*-test.xml">
else="**/test.xml,*-test.xml">
<isset property="${antunit.testcase}" />
</condition>



Loading…
Cancel
Save