try {
executeTarget("hasscript");
}
catch (Throwable ex) {
System.out.println(
test + ": skipped - script not present ");
return false;
}
return true;
try {
Class.forName(TEST_CLASS);
} catch (ClassNotFoundException e) {
return false;
}
return true;
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/tests/junit/org/apache/tools/ant/filters/TokenFilterTest.java
|
|
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/Diagnostics.java
|
Method name: boolean hasScript(String)
|
|
Method name: boolean isOptionalAvailable()
|
Number of AST nodes: 3
|
|
Number of AST nodes: 3
|
|
1 | try {↵ | | 1 | try {↵
|
2 | executeTarget("hasscript");↵ | | 2 | Class.forName(TEST_CLASS);↵
|
3 | }↵ | | 3 | }↵
|
4 | catch (Throwable ex) {↵ | | |
|
5 | System.out.println(↵ | | |
|
6 | test + ": skipped - script not present ");↵ | | 4 | catch (ClassNotFoundException e) {↵
|
7 | return false;↵ | | 5 | return false;↵
|
8 | }↵ | | 6 | }↵
|
9 | return true; | | 7 | return true;
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 0 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.1 |
Clones location | Clones are in different classes |
Number of node comparisons | 1 |