Package de.hybris.ant.taskdefs.yunit
Class BatchTest
java.lang.Object
de.hybris.ant.taskdefs.yunit.BaseTest
de.hybris.ant.taskdefs.yunit.BatchTest
Create then run
JUnitTest's based on the list of files given by the fileset attribute.
Every .java or .class file in the fileset is assumed to be a testcase. A
JUnitTest is created for each of these named classes with basic setup inherited from the parent
BatchTest.- See Also:
-
Field Summary
Fields inherited from class de.hybris.ant.taskdefs.yunit.BaseTest
destDir, errorProperty, failureProperty, filtertrace, fork, formatters, haltOnError, haltOnFail, ifProperty, suppressJunitTenant, unlessProperty -
Constructor Summary
ConstructorsConstructorDescriptionBatchTest(org.apache.tools.ant.Project project) create a new batchtest instance -
Method Summary
Modifier and TypeMethodDescriptionvoidadd(org.apache.tools.ant.types.ResourceCollection rc) Add a new ResourceCollection instance to this batchtest.voidaddFileSet(org.apache.tools.ant.types.FileSet fs) Add a new fileset instance to this batchtest.elements()Return all JUnitTest instances obtain by applying the fileset rules.static StringjavaToClass(String filename) Convenient method to convert a pathname without extension to a fully qualified classname.voidsetAnnotations(String annotationString) voidsetExcludedPackages(String packages) voidsetExtensions(String extensions) voidsetPackages(String packages) voidsetReplaced(String replaced) voidvoidsetWebTests(String value) Methods inherited from class de.hybris.ant.taskdefs.yunit.BaseTest
addFormatter, getErrorProperty, getFailureProperty, getFiltertrace, getFork, getHaltonerror, getHaltonfailure, getTodir, isSuppressJunitTenant, setErrorProperty, setFailureProperty, setFiltertrace, setFork, setHaltonerror, setHaltonfailure, setIf, setSuppressJunitTenant, setTodir, setUnless
-
Constructor Details
-
BatchTest
public BatchTest(org.apache.tools.ant.Project project) create a new batchtest instance- Parameters:
project- the project it depends on.
-
-
Method Details
-
setWebTests
-
setExtensions
- Throws:
Exception
-
setExcludedPackages
- Throws:
Exception
-
setPackages
- Throws:
Exception
-
setReplaced
-
setSplit
-
setAnnotations
-
addFileSet
public void addFileSet(org.apache.tools.ant.types.FileSet fs) Add a new fileset instance to this batchtest. Whatever the fileset is, only filename that are .java or .class will be considered as 'candidates'.- Parameters:
fs- the new fileset containing the rules to get the testcases.
-
add
public void add(org.apache.tools.ant.types.ResourceCollection rc) Add a new ResourceCollection instance to this batchtest. Whatever the collection is, only names that are .java or .class will be considered as 'candidates'.- Parameters:
rc- the new ResourceCollection containing the rules to get the testcases.- Since:
- Ant 1.7
-
elements
Return all JUnitTest instances obtain by applying the fileset rules.- Returns:
- an enumeration of all elements of this batchtest that are a JUnitTest instance.
-
javaToClass
Convenient method to convert a pathname without extension to a fully qualified classname. For example org/apache/Whatever will be converted to org.apache.Whatever- Parameters:
filename- the filename to "convert" to a classname.- Returns:
- the classname matching the filename.
-