void testNoEmptySchemaNamespace() throws Exception { expectBuildExceptionContaining("testNoEmptySchemaNamespace", "empty namespace URI",SchemaValidate.SchemaLocation.ERROR_NO_URI); } public 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);
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 testNoEmptySchemaNamespace() throws Exception {
1
void testBothSrc() throws Exception {
2
        expectBuildExceptionContaining("testNoEmptySchemaNamespace",
2
        expectBuildExceptionContaining("test
3
                "empty namespace URI",SchemaValidate.SchemaLocation.ERROR_NO_URI);
4
    }
5
    public void testNoEmptySchemaLocation
3
BothSrc",
4
                "expected failure",
5
                WsdlToDotnet.Schema.ERROR_BOTH_DECLARED);
6
    }
7
     /**
8
     * A unit test for JUnit
9
     */
6
() throws Exception {
10
    public void testSrcIsDir() throws Exception {
7
        expectBuildExceptionContaining("testNoEmptySchemaLocation",
11
        expectBuildExceptionContaining("testSrcIsDir",
8
                "empty schema location",
12
                "e
9
                SchemaValidate.SchemaLocation.ERROR_NO_LOCATION);
10
    }
13
xpected failure",
14
                WsdlToDotnet.Schema.ERROR_FILE_IS_DIR);
15
    }
16
    /**
17
     * A unit test for JUnit
18
     */
11
    public void testNoFile() throws Exception {
19
    public void testSrcIsMissing() throws Exception {
12
        expectBuildExceptionContaining("testNoFile",
20
        expectBuildExceptionContaining("testSrcIsMissing",
13
                "no file at file attribute",
21
                "
14
                SchemaValidate.SchemaLocation
22
expected failure",
15
.ERROR_NO_FILE);
23
                WsdlToDotnet.Schema.ERROR_FILE_NOT_FOUND);
16
    
24
    
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