ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mugdha Acharya <mugdha.acha...@mir3.com>
Subject run junit categories from ant
Date Wed, 06 Oct 2010 17:23:56 GMT
How do you run junit categories from ant. It will be nice if someone
can post an example. I have tried following 

Java code-

@RunWith(Categories.class)
@IncludeCategory(MyCategory.class)
@SuiteClasses( {A.class }) // A.class has test methods with category
myCategory
public class MyCategorySuite{
}



In build.xml -
<target name="run-my-category"> 
    <junit printsummary="on">
	<classpath refid="runtime-tests-classpath"/>
	<classpath refid="cobertura.classpath"/>
	<formatter type="brief" usefile="false" />
	<test name="${runtimeTest-src.dir}/MyCategorySuite"/>			    
    </junit>
</target>

ant is running just MyCategorySuite and complaining about not finding
any method to test. What am I missing here?


Thanks,
Mugdha

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message