Package de.hybris.ant.taskdefs.yunit
Class BatchTest
- java.lang.Object
-
- de.hybris.ant.taskdefs.yunit.BaseTest
-
- de.hybris.ant.taskdefs.yunit.BatchTest
-
public final class BatchTest extends BaseTest
Create then runJUnitTest's based on the list of files given by the fileset attribute. Every.javaor.classfile in the fileset is assumed to be a testcase. AJUnitTestis created for each of these named classes with basic setup inherited from the parentBatchTest.- See Also:
JUnitTest
-
-
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
Constructors Constructor Description BatchTest(org.apache.tools.ant.Project project)create a new batchtest instance
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(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.java.util.Enumerationelements()Return all JUnitTest instances obtain by applying the fileset rules.static java.lang.StringjavaToClass(java.lang.String filename)Convenient method to convert a pathname without extension to a fully qualified classname.voidsetAnnotations(java.lang.String annotationString)voidsetExcludedPackages(java.lang.String packages)voidsetExtensions(java.lang.String extensions)voidsetPackages(java.lang.String packages)voidsetReplaced(java.lang.String replaced)voidsetSplit(java.lang.String split)voidsetWebTests(java.lang.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
-
-
-
-
Method Detail
-
setWebTests
public void setWebTests(java.lang.String value)
-
setExtensions
public void setExtensions(java.lang.String extensions) throws java.lang.Exception- Throws:
java.lang.Exception
-
setExcludedPackages
public void setExcludedPackages(java.lang.String packages) throws java.lang.Exception- Throws:
java.lang.Exception
-
setPackages
public void setPackages(java.lang.String packages) throws java.lang.Exception- Throws:
java.lang.Exception
-
setReplaced
public void setReplaced(java.lang.String replaced)
-
setSplit
public void setSplit(java.lang.String split)
-
setAnnotations
public void setAnnotations(java.lang.String annotationString)
-
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
public java.util.Enumeration 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
public static java.lang.String javaToClass(java.lang.String filename)
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.
-
-