File path: /hibernate-distribution-3.3.2.GA/project/cache-jbosscache2/src/test/java/org/hibernate/test/util/CacheTestUtil.java | File path: /hibernate-distribution-3.3.2.GA/project/testing/src/main/java/org/hibernate/junit/UnitTestCase.java | |||
Method name: TestSuite createFailureExpectedSuite(Class)
|
Method name: TestSuite createFailureExpectedSuite(Class)
|
|||
Number of AST nodes: 6 | Number of AST nodes: 6 | |||
1 | while (tests.hasMoreElements()) {↵ | 1 | while (tests.hasMoreElements()) {↵ | |
2 | ↵ | |||
3 | Test t = (Test) tests.nextElement();↵ | 2 | Test t = (Test) tests.nextElement();↵ | |
4 | ↵ | |||
5 | if (t instanceof TestCase) {↵ | 3 | if (t instanceof TestCase) {↵ | |
6 | ↵ | |||
7 | String name = ((TestCase) t).getName();↵ | 4 | String name = ((TestCase) t).getName();↵ | |
8 | ↵ | |||
9 | if (name.endsWith("FailureExpected"))↵ | 5 | if (name.endsWith("FailureExpected"))↵ | |
10 | ↵ | |||
11 | failureExpected.add(name);↵ | 6 | failureExpected.add(name);↵ | |
12 | ↵ | |||
13 | } ↵ | 7 | } ↵ | |
14 | ↵ | |||
15 | } | 8 | } | |
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) | 0.2 |
Clones location | Clones are in different classes |
Number of node comparisons | 12 |
Number of mapped statements | 6 |
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.8 |
Clone type | Type 1 |
ID | Statement | ID | Statement | |
---|---|---|---|---|
4 | while (tests.hasMoreElements()) | 4 | while (tests.hasMoreElements()) | |
5 | Test t = (Test)tests.nextElement(); | 5 | Test t = (Test)tests.nextElement(); | |
6 | if (t instanceof TestCase) | 6 | if (t instanceof TestCase) | |
7 | String name = ((TestCase)t).getName(); | 7 | String name = ((TestCase)t).getName(); | |
8 | if (name.endsWith("FailureExpected")) | 8 | if (name.endsWith("FailureExpected")) | |
9 | failureExpected.add(name); | 9 | failureExpected.add(name); |
Row | Violation |
---|