Return-Path: Delivered-To: apmail-ant-user-archive@www.apache.org Received: (qmail 27344 invoked from network); 24 Sep 2004 10:24:50 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 24 Sep 2004 10:24:50 -0000 Received: (qmail 15575 invoked by uid 500); 24 Sep 2004 10:26:16 -0000 Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 15302 invoked by uid 500); 24 Sep 2004 10:26:05 -0000 Mailing-List: contact user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Ant Users List" Reply-To: "Ant Users List" Delivered-To: mailing list user@ant.apache.org Received: (qmail 15159 invoked by uid 99); 24 Sep 2004 10:26:03 -0000 X-ASF-Spam-Status: No, hits=0.1 required=10.0 tests=DNS_FROM_RFC_ABUSE X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy) Received: from [206.190.39.186] (HELO web52909.mail.yahoo.com) (206.190.39.186) by apache.org (qpsmtpd/0.28) with SMTP; Fri, 24 Sep 2004 03:26:01 -0700 Message-ID: <20040924102559.71363.qmail@web52909.mail.yahoo.com> Received: from [212.95.183.130] by web52909.mail.yahoo.com via HTTP; Fri, 24 Sep 2004 03:25:59 PDT Date: Fri, 24 Sep 2004 03:25:59 -0700 (PDT) From: Ivan Ivanov Subject: Re: Choosing junit tests To: Ant Users List In-Reply-To: <20040924101320.174748505@scorpion5.uol.com.br> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Yes, there is but it is JUnit Specific. Create a TestSuite and add your tests in it (copied from [1] and modified for your sample): TestSuite suite= new TestSuite(); suite.addTest(new MoneyTest("testCase2")); suite.addTest(new MoneyTest("testCase3")); TestResult result= suite.run(); However, I used the above way to instantiate a TestSuite only once, when I needed my test case run in a specific sequence. For all other cases, I use (also taken from [1]) TestSuite suite= new TestSuite(MyTestCase.class); TestResult result= suite.run(); Happy juniting Ivan [1]http://junit.sourceforge.net/doc/cookbook/cookbook.htm --- Andr� Dantas Rocha wrote: > Hi, > > Is there a way to specify the junit tests to run? > > Something like this: > > public classe MyTestCase extends TestCase { > public void testCase1 {} > public void testCase2 {} > public void testCase3 {} > } > > I would like to run only testCase2 and testCase3. Is > it possible? > > Thanks, > > Andr� > __________________________________ Do you Yahoo!? Yahoo! Mail is new and improved - Check it out! http://promotions.yahoo.com/new_mail --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org