FileDocCategorySizeDatePackage
PackageNameMapperTest.javaAPI DocApache Ant 1.701545Wed Dec 13 06:16:22 GMT 2006None

PackageNameMapperTest

public class PackageNameMapperTest extends TestCase

Fields Summary
Constructors Summary
public PackageNameMapperTest(String name)

 super(name); 
Methods Summary
private java.lang.StringfixupPath(java.lang.String file)

        return file.replace('/", File.separatorChar);
    
public voidtestMapping()

        PackageNameMapper mapper = new PackageNameMapper();
        mapper.setFrom("*.java");
        mapper.setTo("TEST-*.xml");
        String file = fixupPath("org/apache/tools/ant/util/PackageNameMapperTest.java");
        String result = mapper.mapFileName(file)[0];

        assertEquals("TEST-org.apache.tools.ant.util.PackageNameMapperTest.xml",
          result);