void testNoEmptySchemaLocation() throws Exception { expectBuildExceptionContaining("testNoEmptySchemaLocation", "empty schema location", SchemaValidate.SchemaLocation.ERROR_NO_LOCATION); } public void testNoFile() throws Exception { expectBuildExceptionContaining("testNoFile", "no file at file attribute", SchemaValidate.SchemaLocation.ERROR_NO_FILE); } public void testNoDoubleSchemaLocation() throws Exception { expectBuildExceptionContaining("testNoDoubleSchemaLocation", "two locations for schemas", SchemaValidate.SchemaLocation.ERROR_TWO_LOCATIONS);
void testNoAlias() { expectBuildExceptionContaining("testNoAlias", "no alias", SignJar.ERROR_NO_ALIAS); } public void testNoFiles() { expectBuildExceptionContaining("testNoFiles", "no files", SignJar.ERROR_NO_SOURCE); } public void testNoStorePass() { expectBuildExceptionContaining("testNoStorePass", "no password", SignJar.ERROR_NO_STOREPASS);
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/tests/junit/org/apache/tools/ant/taskdefs/optional/SchemaValidateTest.java File path: /apache-ant-1.7.0/src/tests/junit/org/apache/tools/ant/taskdefs/SignJarTest.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
void testNoEmptySchemaLocation() throws Exception {
1
void testNoAlias() {
2
        expectBuildExceptionContaining("testNoEmptySchemaLocation",
2
        expectBuildExceptionContaining("testNoAlias",
3
                "empty schema location",
3
                "
4
                SchemaValidate.SchemaLocation
4
no alias",
5
.ERROR_NO_LOCATION);
5
                SignJar.ERROR_NO_ALIAS);
6
    }
6
    }
7
    public void testNoFile() throws Exception {
7
    public void testNoFiles() {
8
        expectBuildExceptionContaining("testNoFile",
8
        expectBuildExceptionContaining("testNoFiles",
9
                "no file at file attribute",
9
                "no files",
10
                SchemaValidate.SchemaLocation.ERROR_NO_FILE);
10
                SignJar.ERROR_NO_SOURCE);
11
    }
11
    }
12
    public void testNoDoubleSchemaLocation() throws Exception {
12
    public void testNoStorePass() {
13
        expectBuildExceptionContaining("testNoDoubleSchemaLocation",
13
        expectBuildExceptionContaining("testNo
14
                "two locations for schemas",
15
                SchemaValidate.SchemaLocation.ERROR_TWO_LOCATION
14
StorePass",
15
                "no password",
16
S);
16
                SignJar.ERROR_NO_STOREPASS);
17
    
17
    
Summary
Number of common nesting structure subtrees0
Number of refactorable cases0
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones location
Number of node comparisons0