| Method from org.apache.tools.ant.taskdefs.optional.junit.BatchTest Detail: |
public void add(ResourceCollection rc) {
resources.add(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'. |
public void addFileSet(FileSet fs) {
add(fs);
// this one is here because the changes to support ResourceCollections
// have broken Magic's JUnitTestTask.
//
// The task adds a FileSet to a BatchTest instance using the
// Java API and without telling the FileSet about its project
// instance. The original code would pass in project on the
// call to getDirectoryScanner - which is now hidden deep into
// Resources.iterator() and not reachable.
if (fs.getProject() == null) {
fs.setProject(project);
}
}
Add a new fileset instance to this batchtest. Whatever the fileset is,
only filename that are .java or .class will be
considered as 'candidates'. |
void addTestsTo(Vector v) {
JUnitTest[] tests = createAllJUnitTest();
v.ensureCapacity(v.size() + tests.length);
for (int i = 0; i < tests.length; i++) {
v.addElement(tests[i]);
}
}
Convenient method to merge the JUnitTests of this batchtest
to a Vector. |
public Enumeration elements() {
JUnitTest[] tests = createAllJUnitTest();
return Enumerations.fromArray(tests);
}
Return all JUnitTest instances obtain by applying the fileset rules. |
public static String javaToClass(String filename) {
return filename.replace(File.separatorChar, '.").replace('/", '.")
.replace('\\", '.");
}
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 |