<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://purl.org/rss/1.0/" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:syn="http://purl.org/rss/1.0/modules/syndication/" xmlns:admin="http://webns.net/mvcb/">
  <channel rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user">
    <title>gmane.comp.jakarta.ant.user</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user</link>
    <description/>
    <syn:updatePeriod>hourly</syn:updatePeriod>
    <syn:updateFrequency>1</syn:updateFrequency>
    <syn:updateBase>1901-01-01T00:00+00:00</syn:updateBase>
    <items>
      <rdf:Seq>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54172"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54171"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54170"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54169"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54168"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54167"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54166"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54165"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54164"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54163"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54162"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54161"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54160"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54159"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54158"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54157"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54156"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54155"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54154"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54153"/>
      </rdf:Seq>
    </items>
    <image rdf:resource="http://gmane.org/img/gmane-25t.png"/>
    <textinput rdf:resource=""/>
  </channel>
  <image rdf:about="http://gmane.org/img/gmane-25t.png">
    <title>Gmane</title>
    <url>http://gmane.org/img/gmane-25t.png</url>
    <link>http://gmane.org</link>
  </image>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54172">
    <title>Re: How to run a single junit test method with ant</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54172</link>
    <description>&lt;pre&gt;Thanks a lot for your help. Problem solved!




On Tue, May 14, 2013 at 3:18 PM, Jan Matèrne (jhm) &amp;lt;apache&amp;lt; at &amp;gt;materne.de&amp;gt;wrote:

&lt;/pre&gt;</description>
    <dc:creator>肖谋</dc:creator>
    <dc:date>2013-05-19T13:42:02</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54171">
    <title>Re: How to run a single junit test method with ant</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54171</link>
    <description>&lt;pre&gt;Thank you  very much!
I missed that important property.

Regards
xiaomou


On Sun, May 12, 2013 at 11:33 PM, Antoine Levy Lambert &amp;lt;antoine&amp;lt; at &amp;gt;gmx.de&amp;gt;wrote:

&lt;/pre&gt;</description>
    <dc:creator>肖谋</dc:creator>
    <dc:date>2013-05-19T13:40:05</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54170">
    <title>AW: editstring macro</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54170</link>
    <description>&lt;pre&gt;No props is one of the developed antlibs, which were never released.
Sources and tests are all available under ASL at ASF servers.
But there is not binary distro, so you must build it yourself (which
shouldn't be more difficult than 
invoking "ant").

Jan

&lt;/pre&gt;</description>
    <dc:creator>Jan Matèrne (jhm</dc:creator>
    <dc:date>2013-05-16T05:08:16</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54169">
    <title>Re: How to invoke the JDK 1.6 annotation processing engine?</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54169</link>
    <description>&lt;pre&gt;In Java 1.6, you access the annotation processor by a flag sent to the
compiler. So you can do the same thing in ANT, using the javac ANT task.

&amp;lt;javac srcdir="${src}" destdir="${src}" excludes="*_.java" source="1.7"&amp;gt;
&amp;lt;classpath refid="lib.path"/&amp;gt;
&amp;lt;compilerarg value="-Aopenjpa.metamodel=true"/&amp;gt;
&amp;lt;/javac&amp;gt;




--
View this message in context: http://ant.1045680.n5.nabble.com/How-to-invoke-the-JDK-1-6-annotation-processing-engine-tp1347722p5714170.html
Sent from the Ant - Users mailing list archive at Nabble.com.
&lt;/pre&gt;</description>
    <dc:creator>OrlandoDFree</dc:creator>
    <dc:date>2013-05-15T23:10:15</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54168">
    <title>Re: editstring macro</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54168</link>
    <description>&lt;pre&gt;Thanks Jan.

I saw the description of propertyhelper in the manual, but got the impression that it was for developing implementations external to the distribution.  Is the props antlib part of the standard distribution? There is nothing that I could see about props antlib in the downloads section of the Apache Props Antlib webpage. Is it part of antunit? I couldn't see any indication of that in antunit jar.

I was after a solution that did _not_ require any additional dependencies.

Peter West

"When the Spirit of truth comes, he will guide you into all the truth..."

On 15/05/2013, at 3:54 PM, Jan Matèrne (jhm) &amp;lt;apache&amp;lt; at &amp;gt;materne.de&amp;gt; wrote:

&lt;/pre&gt;</description>
    <dc:creator>Peter West</dc:creator>
    <dc:date>2013-05-15T21:58:45</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54167">
    <title>Re: &lt;target unless=...&gt;</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54167</link>
    <description>&lt;pre&gt;Ahhh, you're using var instead of property.  I missed that before.  Since you instantiate it first, the scope remains over the antcalls.  Beautiful, thanks Budd!
 
Eric

----- Original Message -----
From: "McNish, Budd" &amp;lt;bmcnish&amp;lt; at &amp;gt;HealthPlan.com&amp;gt;
To: Ant Users List &amp;lt;user&amp;lt; at &amp;gt;ant.apache.org&amp;gt;; 'Eric Fetzer' &amp;lt;elstonkers&amp;lt; at &amp;gt;yahoo.com&amp;gt;
Cc: 
Sent: Wednesday, May 15, 2013 9:36 AM
Subject: RE: &amp;lt;target unless=...&amp;gt;

Eric,

Okay try this one.

&amp;lt;project default="invalid"&amp;gt;
  &amp;lt;target name="invalid"&amp;gt;
      &amp;lt;taskdef resource="net/sf/antcontrib/antcontrib.properties"&amp;gt;
      &amp;lt;classpath location="${antcontrib.jar}"/&amp;gt;
    &amp;lt;/taskdef&amp;gt;
      &amp;lt;var name="testit" value="" /&amp;gt;
      &amp;lt;antcall target="test1" inheritall="true" /&amp;gt;
    &amp;lt;antcall target="test2" inheritall="true" /&amp;gt;
  &amp;lt;/target&amp;gt;
  &amp;lt;target name="test1" depends="setvalue"&amp;gt;
    &amp;lt;echo message="in test1 and value of testit is:  ${testit}"/&amp;gt;
  &amp;lt;/target&amp;gt;
  &amp;lt;target name="test2" unless="testit"&amp;gt;
    &amp;lt;echo message="in test2"/&amp;gt;
    &amp;lt;echo message="value of testit &lt;/pre&gt;</description>
    <dc:creator>Eric Fetzer</dc:creator>
    <dc:date>2013-05-15T15:59:05</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54166">
    <title>RE: &lt;target unless=...&gt;</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54166</link>
    <description>&lt;pre&gt;Eric,

Okay try this one.

&amp;lt;project default="invalid"&amp;gt;
  &amp;lt;target name="invalid"&amp;gt;
  &amp;lt;taskdef resource="net/sf/antcontrib/antcontrib.properties"&amp;gt;
      &amp;lt;classpath location="${antcontrib.jar}"/&amp;gt;
    &amp;lt;/taskdef&amp;gt;
   &amp;lt;var name="testit" value="" /&amp;gt;
   &amp;lt;antcall target="test1" inheritall="true" /&amp;gt;
     &amp;lt;antcall target="test2" inheritall="true" /&amp;gt;
  &amp;lt;/target&amp;gt;
  &amp;lt;target name="test1" depends="setvalue"&amp;gt;
    &amp;lt;echo message="in test1 and value of testit is:  ${testit}"/&amp;gt;
  &amp;lt;/target&amp;gt;
  &amp;lt;target name="test2" unless="testit"&amp;gt;
    &amp;lt;echo message="in test2"/&amp;gt;
    &amp;lt;echo message="value of testit is:  ${testit}"/&amp;gt;
  &amp;lt;/target&amp;gt;
  &amp;lt;target name="setvalue"&amp;gt;
   &amp;lt;echo&amp;gt;setting the value to 1.2.3.4&amp;lt;/echo&amp;gt;
   &amp;lt;var name="testit" value="1.2.3.4" /&amp;gt;
   &amp;lt;echo&amp;gt;testit = ${testit}&amp;lt;/echo&amp;gt;
  &amp;lt;/target&amp;gt;
&amp;lt;/project&amp;gt;

C:\IBM&amp;gt;ant -f /temp/throw.xml
Buildfile: C:\temp\throw.xml

invalid:

setvalue:
     [echo] setting the value to 1.2.3.4
     [echo] testit = 1.2.3.4

test1:
     [echo] in test1 and value of testit is:  1.2.3.4

test2:

BUILD SUCCESSFUL&lt;/pre&gt;</description>
    <dc:creator>McNish, Budd</dc:creator>
    <dc:date>2013-05-15T15:36:07</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54165">
    <title>Re: &lt;target unless=...&gt;</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54165</link>
    <description>&lt;pre&gt;Sorry Budd, it looks like I wasn't clear on one aspect of this.  The value of this property must be set inside of the first target called.  In reality, the first target called has a depends target that may set this property.  Based on whether it sets that property, we may or may not want to come back to that target again.  So a more valid repro would be:

&amp;lt;project name="test" default="testIt"&amp;gt;
  &amp;lt;taskdef resource="net/sf/antcontrib/antlib.xml"/&amp;gt;
  &amp;lt;target name="testIt"&amp;gt;
     &amp;lt;antcall target="test1" inheritall="true" /&amp;gt;
     &amp;lt;echo message="back out to main target, label is:  ${label}"/&amp;gt;
     &amp;lt;antcall target="test2" inheritall="true" /&amp;gt;
  &amp;lt;/target&amp;gt;
  &amp;lt;target name="test1" depends="setLabel" &amp;gt;
    &amp;lt;echo message="in test1 and value of label is:  ${label}"/&amp;gt;
  &amp;lt;/target&amp;gt;
  &amp;lt;target name="test2" depends="setLabel"&amp;gt;
    &amp;lt;echo message="in test2"/&amp;gt;
    &amp;lt;echo message="value of label is:  ${label}"/&amp;gt;
  &amp;lt;/target&amp;gt;
  &amp;lt;target name="setLabel" unless="label"&amp;gt;
    &amp;lt;property name="label"&lt;/pre&gt;</description>
    <dc:creator>Eric Fetzer</dc:creator>
    <dc:date>2013-05-15T15:21:20</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54164">
    <title>RE: &lt;target unless=...&gt;</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54164</link>
    <description>&lt;pre&gt;This works.

&amp;lt;project default="invalid"&amp;gt;
  &amp;lt;target name="invalid"&amp;gt;
   &amp;lt;property name="testit" value="" /&amp;gt;
   &amp;lt;antcall target="test1" inheritall="true" &amp;gt;
     &amp;lt;param name="testit" value="true"/&amp;gt;
   &amp;lt;/antcall&amp;gt;
     &amp;lt;antcall target="test2" inheritall="true" /&amp;gt;
  &amp;lt;/target&amp;gt;
  &amp;lt;target name="test1"&amp;gt;
    &amp;lt;echo message="in test1 and value of testit is:  ${testit}"/&amp;gt;
  &amp;lt;/target&amp;gt;
  &amp;lt;target name="test2" unless="testit"&amp;gt;
    &amp;lt;echo message="in test2"/&amp;gt;
    &amp;lt;echo message="value of testit is:  ${testit}"/&amp;gt;
  &amp;lt;/target&amp;gt;

&amp;lt;/project&amp;gt;

C:\IBM&amp;gt;ant -f /temp/throw.xml
Buildfile: C:\temp\throw.xml

invalid:

test1:
     [echo] in test1 and value of testit is:  true

test2:

BUILD SUCCESSFUL
Total time: 0 seconds

C:\IBM&amp;gt;

Budd A. McNish

Health Plan Services
813-289-1000 ext. 2352




-----Original Message-----
From: Eric Fetzer [mailto:elstonkers&amp;lt; at &amp;gt;yahoo.com] 
Sent: Wednesday, May 15, 2013 10:14 AM
To: Ant Users
Subject: &amp;lt;target unless=...&amp;gt;

Hi!  I've found that my unless= is somewhat useless when using &amp;lt;antcall&amp;gt;.  Here's a rep&lt;/pre&gt;</description>
    <dc:creator>McNish, Budd</dc:creator>
    <dc:date>2013-05-15T14:48:08</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54163">
    <title>&lt;target unless=...&gt;</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54163</link>
    <description>&lt;pre&gt;Hi!  I've found that my unless= is somewhat useless when using &amp;lt;antcall&amp;gt;.  Here's a repro for what I'm trying to do:
 
&amp;lt;project name="test" default="testIt"&amp;gt;
  &amp;lt;taskdef resource="net/sf/antcontrib/antlib.xml"/&amp;gt;
  &amp;lt;target name="testIt"&amp;gt;
     &amp;lt;antcall target="test1" inheritall="true" /&amp;gt;
     &amp;lt;antcall target="test2" inheritall="true" /&amp;gt;
  &amp;lt;/target&amp;gt;
  &amp;lt;target name="test1"&amp;gt;
    &amp;lt;property name="testit" value="true"/&amp;gt;
    &amp;lt;echo message="in test1 and value of testit is:  ${testit}"/&amp;gt;
  &amp;lt;/target&amp;gt;
  &amp;lt;target name="test2" unless="testit"&amp;gt;
    &amp;lt;echo message="in test2"/&amp;gt;
    &amp;lt;echo message="value of testit is:  ${testit}"/&amp;gt;
  &amp;lt;/target&amp;gt;
&amp;lt;/project&amp;gt;
 
And the results that I'm sure you anticipate as you understand how antcall works:
 
[me&amp;lt; at &amp;gt;myMachine]$ ant -f test.xml
Buildfile: test.xml
testIt:
test1:
     [echo] in test1 and value of testit is:  true
test2:
     [echo] in test2
     [echo] value of testit is:  ${testit}
BUILD SUCCESSFUL
Total time: 0 seconds
 
 
My actual antca&lt;/pre&gt;</description>
    <dc:creator>Eric Fetzer</dc:creator>
    <dc:date>2013-05-15T14:13:34</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54162">
    <title>Java task - why is redirecting out stream to file not compatible with spawn</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54162</link>
    <description>&lt;pre&gt;Hi

I'm starting a process by configuring and executing Ant Java task from
my software, see:
https://maven-play-plugin.googlecode.com/svn/mavensite/1.0.0-beta5/play-maven-plugin/xref/com/google/code/play/AbstractAntJavaBasedPlayMojo.html
https://maven-play-plugin.googlecode.com/svn/mavensite/1.0.0-beta5/play-maven-plugin/xref/com/google/code/play/AbstractPlayServerMojo.html
https://maven-play-plugin.googlecode.com/svn/mavensite/1.0.0-beta5/play-maven-plugin/xref/com/google/code/play/AbstractPlayStartServerMojo.html

Sometimes I need to redirect output stream to a file when starting
external process. This is configurable,
but by default I start it with spawn flag set. When spawning, I cannot
redirect process'es output stream to a file, Ant does not allow it. I
wonder why.

I found a workaround:
When spawning I set system property telling spawned process to redirect
its output to a file:
https://maven-play-plugin.googlecode.com/svn/mavensite/1.0.0-beta5/play-maven-plugin/xref/com/google/code/play/AbstractPlayS&lt;/pre&gt;</description>
    <dc:creator>Grzegorz Słowikowski</dc:creator>
    <dc:date>2013-05-15T14:02:45</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54161">
    <title>AW: editstring macro</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54161</link>
    <description>&lt;pre&gt;Have you tried Ant Props?
http://ant.apache.org/antlibs/props/index.html
https://svn.apache.org/repos/asf/ant/antlibs/props/trunk/src/tests/antunit/s
tringops-test.xml
- testReplaceFirst
- testReplaceAll
- testPackageMapping

Jan

&lt;/pre&gt;</description>
    <dc:creator>Jan Matèrne (jhm</dc:creator>
    <dc:date>2013-05-15T05:54:40</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54160">
    <title>editstring macro</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54160</link>
    <description>&lt;pre&gt;I have posted a discussion and code for a macro to edit a string value, placing the result into a property.  I'm sure various people have done the same sort of thing before, but this might be a handy reference.

http://codepulsive.blogspot.com.au/2013/05/ant-edit-property-values.html

An example build.xml is available at &amp;lt;http://pbw.id.au/editstring/build.xml&amp;gt;.


Peter West

"When the Spirit of truth comes, he will guide you into all the truth..."
&lt;/pre&gt;</description>
    <dc:creator>Peter West</dc:creator>
    <dc:date>2013-05-15T02:08:24</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54159">
    <title>AW: How to run a single junit test method with ant</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54159</link>
    <description>&lt;pre&gt;Here is a skeleton which could be what you need.
  ant test -Dtestclass=xy -Dtestmethod=xy  :  runs the testmethod in that test class
  ant test -Dtestclass=xy                  :  runs all tests in that test class
  ant test                -Dtestmethod=xy  :  invalid as the class must be specified, so fail the build
  ant test                                 :  runs all tests


Jan


&amp;lt;project&amp;gt;

    &amp;lt;target name="-test.check"&amp;gt;
        &amp;lt;!-- 
        decision matrix:
                testclass   testmethod
        suite      -             -
        class      X             -
        method     X             X
        error      -             X
        --&amp;gt;
        &amp;lt;condition property="testaction.suite"&amp;gt;
            &amp;lt;and&amp;gt;
                &amp;lt;not&amp;gt;&amp;lt;isset property="testclass"/&amp;gt;&amp;lt;/not&amp;gt;
                &amp;lt;not&amp;gt;&amp;lt;isset property="testmethod"/&amp;gt;&amp;lt;/not&amp;gt;
            &amp;lt;/and&amp;gt;    
        &amp;lt;/condition&amp;gt;
        &amp;lt;condition property="testaction.class"&amp;gt;
            &amp;lt;and&amp;gt;
                &amp;lt;isset property="testclass"/&amp;gt;
                &amp;lt;not&amp;gt;&amp;lt;is&lt;/pre&gt;</description>
    <dc:creator>Jan Matèrne (jhm</dc:creator>
    <dc:date>2013-05-14T07:18:09</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54158">
    <title>Re: How to run a single junit test method with ant</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54158</link>
    <description>&lt;pre&gt;Hello Xiaomou,

the documentation of the junit task http://ant.apache.org/manual/Tasks/junit.html 
mentions that the test nested element can have a methods attribute to specify the methods you want to run

Comma-separated list of names of test case methods to execute. Since 1.8.2

&amp;lt;junit …&amp;gt;
   &amp;lt;test name="com.something.XyzTest" methods="test1"&amp;gt;
   &amp;lt;/test&amp;gt;
&amp;lt;/junit&amp;gt;

Regards,

Antoine
On May 11, 2013, at 2:15 PM, 肖谋 wrote:


&lt;/pre&gt;</description>
    <dc:creator>Antoine Levy Lambert</dc:creator>
    <dc:date>2013-05-12T15:33:37</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54157">
    <title>Re: How to run a single junit test method with ant</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54157</link>
    <description>&lt;pre&gt;Thanks for your reply. Perhaps I did not express my problem clearly, or may
not understand your solution.
My problem is : I have junit test class:
class TestService {
  &amp;lt; at &amp;gt;Test
   void test1() {}
  &amp;lt; at &amp;gt;Test
   void test2() {}
}

now I'd like to only test the "test2" with ant command line like this:
ant -Dtest=TestService -Dtestcase=test2 test-target
Then how to write the build.xml?

Thanks


XiaoMou





On Sat, May 11, 2013 at 4:00 PM, Jan Matèrne (jhm) &amp;lt;apache&amp;lt; at &amp;gt;materne.de&amp;gt;
 wrote:

&lt;/pre&gt;</description>
    <dc:creator>肖谋</dc:creator>
    <dc:date>2013-05-11T18:15:53</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54156">
    <title>AW: How to run a single junit test method with ant</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54156</link>
    <description>&lt;pre&gt;Basic idea is
- specify the test to run via command line property (-Dtestcase=...)
- test-targets depends on two targets running a single test or the whole test suite
   &amp;lt;target name="test" depends="-test.single,-test.all"/&amp;gt;
- that two targets are conditional according to that property
   &amp;lt;target name="-test.single" if="testcase"&amp;gt;
   &amp;lt;target name="-test.all" unless="testcase"&amp;gt;

Jan

&lt;/pre&gt;</description>
    <dc:creator>Jan Matèrne (jhm</dc:creator>
    <dc:date>2013-05-11T08:00:39</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54155">
    <title>Re: How to run a single junit test method with ant</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54155</link>
    <description>&lt;pre&gt;Typically this would be done using separate targets.  Ant's own build.xml
provides an example.

HTH,
Matt


On Thu, May 9, 2013 at 11:33 PM, 肖谋 &amp;lt;xiaomou&amp;lt; at &amp;gt;gmail.com&amp;gt; wrote:

&lt;/pre&gt;</description>
    <dc:creator>Matt Benson</dc:creator>
    <dc:date>2013-05-10T14:54:51</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54154">
    <title>How to run a single junit test method with ant</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54154</link>
    <description>&lt;pre&gt;Hi, Users.
   I am using ant in Linux. I can use ant junit task to run all test
methods in a junit4 test class but fail to find the way to  run a single
test method.  I googled and found a helpful article at
https://today.java.net/pub/a/today/2003/09/12/individual-test-cases.html.
However, the solution it provides does not help. My ant seems not to
recognize the "tests" sysproperty.
  My ant version is 1.8.4. and the related content of build.xml is listed
as follows:

   &amp;lt;target name="ensure-test-name" unless="test"&amp;gt;
        &amp;lt;fail message="You must run this target with -Dtest=TestName"/&amp;gt;
    &amp;lt;/target&amp;gt;

    &amp;lt;target name="run-general-test" description="Runs the test you specify
on the command
        line with -Dtest=" depends="compile, ensure-test-name"&amp;gt;
        &amp;lt;junit printsummary="withOutAndErr" fork="true"&amp;gt;
            &amp;lt;sysproperty key="tests" value="${tests}"/&amp;gt;
            &amp;lt;classpath refid="test.classpath" /&amp;gt;
            &amp;lt;formatter type="plain" usefile="false"/&amp;gt;
            &amp;lt;batchtest&amp;gt;
                &amp;lt;fi&lt;/pre&gt;</description>
    <dc:creator>肖谋</dc:creator>
    <dc:date>2013-05-10T04:33:04</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54153">
    <title>Re: How to apply mapper to filelist to get other fileset or filelist?</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54153</link>
    <description>&lt;pre&gt;Hello Lev,

Ant has a concept of mapped resources.

Read this : http://ant.apache.org/manual/Types/resources.html#mappedresources

Best regards,

Antoine

On May 6, 2013, at 10:14 AM, Lev Serebryakov wrote:


&lt;/pre&gt;</description>
    <dc:creator>Antoine Levy Lambert</dc:creator>
    <dc:date>2013-05-08T01:52:06</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54152">
    <title>How to apply mapper to filelist to get other fileset or filelist?</title>
    <link>http://permalink.gmane.org/gmane.comp.jakarta.ant.user/54152</link>
    <description>&lt;pre&gt;Hello, User.

  Is it possible to apply mapper to &amp;lt;filelist&amp;gt; to get other &amp;lt;filelist&amp;gt;
  or, even better, &amp;lt;fileset&amp;gt;? For example, if I have list of classes
  and root source dir,  how could I get &amp;lt;fileset&amp;gt; which contains all
  source files? Something like this:

&amp;lt;fileset dir="${root}"&amp;gt;
  &amp;lt;filelist files="${list.of.classes}/&amp;gt;
  &amp;lt;unpackagemapper from="*" to="*.java /&amp;gt;
&amp;lt;/fileset&amp;gt;

 But it doesn't work :(

&lt;/pre&gt;</description>
    <dc:creator>Lev Serebryakov</dc:creator>
    <dc:date>2013-05-06T14:14:57</dc:date>
  </item>
  <textinput rdf:about="http://search.gmane.org/?group=$group=gmane.comp.jakarta.ant.user">
    <title>Search Engine</title>
    <description>Search the mailing list at Gmane</description>
    <name>query</name>
    <link>http://search.gmane.org/?group=$group=gmane.comp.jakarta.ant.user</link>
  </textinput>
</rdf:RDF>
