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 testBothSrc() throws Exception { expectBuildExceptionContaining("testBothSrc", "expected failure", WsdlToDotnet.Schema.ERROR_BOTH_DECLARED); } /** * A unit test for JUnit */ public void testSrcIsDir() throws Exception { expectBuildExceptionContaining("testSrcIsDir", "expected failure", WsdlToDotnet.Schema.ERROR_FILE_IS_DIR); } /** * A unit test for JUnit */ public void testSrcIsMissing() throws Exception { expectBuildExceptionContaining("testSrcIsMissing", "expected failure", WsdlToDotnet.Schema.ERROR_FILE_NOT_FOUND);
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/optional/WsdlToDotnetTest.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
void testNoEmptySchemaLocation() throws Exception {
1
void testBothSrc() throws Exception {
2
        expectBuildExceptionContaining("testNoEmptySchemaLocation",
2
        expectBuildExceptionContaining("testBothSrc",
3
                "empty schema location",
3
                "e
4
                SchemaValidate.SchemaLocation.ERROR_NO_LOCATION);
5
    }
4
xpected failure",
5
                WsdlToDotnet.Schema.ERROR_BOTH_DECLARED);
6
    }
7
     /**
8
     * A unit test for JUnit
9
     */
6
    public void testNoFile() throws Exception {
10
    public void testSrcIsDir() throws Exception {
7
        expectBuildExceptionContaining("testNoFile",
11
        expectBuildExceptionContaining("testSrcIsDir",
8
                "no file at file attribute",
12
                "expected failure",
9
                SchemaValidate.SchemaLocation.ERROR_NO_FILE);
13
                WsdlToDotnet.Schema.ERROR_FILE_IS_DIR);
10
    }
14
    }
11
    public void testNoDoubleSchemaLocation
15
    /**
16
     * A unit test for JUnit
17
     */
12
() throws Exception {
18
    public void testSrcIsMissing() throws Exception {
13
        expectBuildExceptionContaining("testNoDoubleSchemaLocation",
19
        expectBuildExceptionContaining("test
14
                "two locations for schemas",
15
                SchemaValidate.SchemaLocation.ERROR_TWO_LOCATIONS
20
SrcIsMissing",
21
                "expected failure",
16
);
22
                WsdlToDotnet.Schema.ERROR_FILE_NOT_FOUND);
17
    
23
    
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