File path: /apache-ant-1.7.0/src/tests/junit/org/apache/tools/ant/DirectoryScannerTest.java | File path: /apache-ant-1.7.0/src/tests/junit/org/apache/tools/ant/DirectoryScannerTest.java | |||
Method name: void testSetFollowLinks()
|
Method name: void testSetFollowLinks()
|
|||
Number of AST nodes: 6 | Number of AST nodes: 7 | |||
1 | included = ds.getIncludedDirectories();↵ | |||
1 | for (int i=0; i<included.length; i++) {↵ | 2 | for (int i=0; i<included.length; i++) {↵ | |
2 | if (included[i].equals("zip")) {↵ | 3 | if (included[i].equals("zip")) {↵ | |
3 | haveZipPackage = true;↵ | 4 | haveZipPackage = true;↵ | |
4 | } else if (included[i].equals("ThisIsALink"↵ | 5 | } else if (included[i].equals("ThisIsALink"↵ | |
5 | + File.separator↵ | 6 | + File.separator↵ | |
6 | + "taskdefs")) {↵ | 7 | + "taskdefs")) {↵ | |
7 | haveTaskdefsPackage = true;↵ | 8 | haveTaskdefsPackage = true;↵ | |
8 | }↵ | 9 | }↵ | |
9 | }↵ | 10 | }↵ | |
10 | // if we followed the symlink we just made we should↵ | |||
11 | // bypass the excludes.↵ | |||
12 | assertTrue("(1) zip package included", haveZipPackage); | 11 | assertTrue("(2) zip package included", haveZipPackage); | |
See real code fragment | See real code fragment |
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 1 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 1.2 |
Clones location | Clones are in the same method |
Number of node comparisons | 17 |
Number of mapped statements | 6 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 1 |
Time elapsed for statement mapping (ms) | 2.9 |
Clone type | Type 3 |
ID | Statement | ID | Statement | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 34 | included = ds.getIncludedDirectories(); | ||||||||||||
20 | for (int i = 0; i < included.length; i++) | 35 | for (int i = 0; i < included.length; i++) | |||||||||||
21 | if (included[i].equals("zip")) | 36 | if (included[i].equals("zip")) | |||||||||||
22 | haveZipPackage = true; | 37 | haveZipPackage = true; | |||||||||||
23 | else if (included[i].equals("ThisIsALink" + File.separator + "taskdefs")) | 38 | else if (included[i].equals("ThisIsALink" + File.separator + "taskdefs")) | |||||||||||
24 | haveTaskdefsPackage = true; | 39 | haveTaskdefsPackage = true; | |||||||||||
25 | assertTrue("(1) zip package included", haveZipPackage); |
| 40 | assertTrue("(2) zip package included", haveZipPackage); |
Row | Violation |
---|