FileDocCategorySizeDatePackage
AntlibTest.javaAPI DocApache Ant 1.702675Wed Dec 13 06:16:22 GMT 2006org.apache.tools.ant.taskdefs

AntlibTest

public class AntlibTest extends org.apache.tools.ant.BuildFileTest

Fields Summary
Constructors Summary
public AntlibTest(String name)

        super(name);
    
Methods Summary
private booleanisSharedJVM()
only do the antlib tests if we are in the same JVM as ant.

return

        String property = System.getProperty("tests.and.ant.share.classloader");
        return property!=null && Project.toBoolean(property);
    
public voidsetUp()

        configureProject("src/etc/testcases/taskdefs/antlib.xml");
    
public voidtestAntlibFile()

        expectLog("antlib.file", "MyTask called");
    
public voidtestAntlibResource()
Confirms that all matching resources will be used, so that you can collect several antlibs in one Definer call.

see
"http://issues.apache.org/bugzilla/show_bug.cgi?id=24024"

        expectLog("antlib.resource", "MyTask called-and-then-MyTask2 called");
    
public voidtestAntlib_uri()

        if (isSharedJVM()) {
            executeTarget("antlib_uri");
        }
    
public voidtestAntlib_uri_auto()

        if (isSharedJVM()) {
            executeTarget("antlib_uri_auto");
        }
    
public voidtestAntlib_uri_auto2()

        if (isSharedJVM()) {
            executeTarget("antlib_uri_auto2");
        }
    
public voidtestNsCurrent()

        expectLog("ns.current", "Echo2 inside a macroHello from x:p");