assertNull(parser2.getErrorString(), parser2.getErrorString());
final List clOptions2 = parser2.getArguments();
final int size2 = clOptions2.size();
assertEquals(size2, 2);
assertEquals(((CLOption) clOptions2.get(0)).getDescriptor().getId(), 0);
assertNull(parser2.getErrorString(), parser2.getErrorString());
final List clOptions2 = parser2.getArguments();
final int size2 = clOptions2.size();
assertEquals(size2, 7);
assertEquals(((CLOption) clOptions2.get(0)).getDescriptor().getId(), 0);
Clone fragments detected by clone detection tool
File path: /jakarta-jmeter-2.3.2/test/src/org/apache/commons/cli/avalon/ClutilTestCase.java
|
|
File path: /jakarta-jmeter-2.3.2/test/src/org/apache/commons/cli/avalon/ClutilTestCase.java
|
Method name: void test2PartPartialParse()
|
|
Method name: void test2PartParse()
|
Number of AST nodes: 5
|
|
Number of AST nodes: 5
|
|
1 | assertNull(parser2.getErrorString(), parser2.getErrorString());↵ | | 1 | assertNull(parser2.getErrorString(), parser2.getErrorString());↵
|
|
2 | final List clOptions2 = parser2.getArguments();↵ | | 2 | final List clOptions2 = parser2.getArguments();↵
|
3 | final int size2 = clOptions2.size();↵ | | 3 | final int size2 = clOptions2.size();↵
|
|
4 | assertEquals(size2, 2);↵ | | 4 | assertEquals(size2, 7);↵
|
5 | assertEquals(((CLOption) clOptions2.get(0)).getDescriptor().getId(), 0); | | 5 | assertEquals(((CLOption) clOptions2.get(0)).getDescriptor().getId(), 0);
|
See real code fragment |
|
See real code fragment |
Summary
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) | 0.0 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 25 |
-
{Refactorable}
Mapping Summary
Number of mapped statements | 5 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 0.0 |
Clone type | Type 2 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
15 | assertNull(parser2.getErrorString(), parser2.getErrorString()); | | 11 | assertNull(parser2.getErrorString(), parser2.getErrorString()); |
16 | final List clOptions2 = parser2.getArguments(); | | 12 | final List clOptions2 = parser2.getArguments(); |
17 | final int size2 = clOptions2.size(); | | 13 | final int size2 = clOptions2.size(); |
18 | assertEquals(size2, 2); | | 14 | assertEquals(size2, 7); |
19 | assertEquals(((CLOption)clOptions2.get(0)).getDescriptor().getId(), 0); | | 15 | assertEquals(((CLOption)clOptions2.get(0)).getDescriptor().getId(), 0); |
Precondition Violations (0)
Row |
Violation |