void testAntTypeTest() { expectLog("antTypeTest", ""); } public void testCorrectTaskNameBadAttr() { expectBuildExceptionContaining( "correct_taskname_badattr", "attribute message", "javac doesn't support the"); } public void testCorrectTaskNameBadEl() { expectBuildExceptionContaining( "correct_taskname_badel", "element message", "javac doesn't support the"); }
void testBasic() { expectPropertySet("basic","basic"); } public void testConditionIncomplete() { expectSpecificBuildException("condition-incomplete", "property attribute has been omitted", "The property attribute is required."); } public void testConditionEmpty() { expectSpecificBuildException("condition-empty", "no conditions", "You must nest a condition into <condition>"); }
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/tests/junit/org/apache/tools/ant/taskdefs/PreSetDefTest.java File path: /apache-ant-1.7.0/src/tests/junit/org/apache/tools/ant/taskdefs/ConditionTest.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
void testAntTypeTest() {
1
void testBasic() {
2
        expectLog("antTypeTest", "");
2
       expectPropertySet("basic","basic");
3
    }
3
    }
4
    public void testCorrectTaskNameBadAttr() {
4
    public void testConditionIncomplete() {
5
        expectBuildExceptionContaining(
5
        expectSpecificBuildException
6
            "correct_taskname_badattr", "attribute message", "javac doesn't support the
6
("condition-incomplete",
7
                                     "property attribute has been omitted",
7
");
8
                                     "The property attribute is required.");
8
    }
9
    }
9
    public void testCorrectTaskNameBadEl() {
10
    public void testConditionEmpty() {
10
        expectBuildExceptionContaining(
11
        expectSpecificBuildException
11
            "correct_taskname_badel", "elemen
12
("condition-empty",
13
                                     "no conditions",
12
t message", "javac doesn't support the");
14
                                     "You must nest a condition into <condition>");
13
    }
15
    }
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