1803-1-4

dataset.add(new BoxAndWhiskerItem(new Double(1.0), new Double(2.0), new Double(0.0), new Double(4.0), new Double(0.5), new Double(4.5), new Double(-0.5), new Double(5.5), null), "S1", "C1"); CategoryPlot plot = new CategoryPlot(dataset, new CategoryAxis("Category"), new NumberAxis("Value"), new BoxAndWhiskerRenderer());
d2.add(new BoxAndWhiskerItem(new Double(1.0), new Double(2.0), new Double(3.0), new Double(4.0), new Double(5.0), new Double(6.0), new Double(7.0), new Double(8.0), new ArrayList()), "ROW1", "COLUMN1"); assertTrue(d1.equals(d2));

Clone fragments detected by clone detection tool
File path: /jfreechart-1.0.10/tests/org/jfree/chart/renderer/category/junit/BoxAndWhiskerRendererTests.java |  | File path: /jfreechart-1.0.10/tests/org/jfree/data/statistics/junit/DefaultBoxAndWhiskerCategoryDatasetTests.java
Method name: `void testDrawWithNullInfo()` |  | Method name: `void testEquals()`
Number of AST nodes: 2 |  | Number of AST nodes: 2

1

    dataset.add(new BoxAndWhiskerItem(new Double(1.0), new Double(2.0),↵

1

    d2.add(new BoxAndWhiskerItem(new Double(1.0), new Double(2.0), ↵

2

                        new Double(0.0), new Double(4.0), new Double(0.5),↵

2

                    new Double(3.0), new Double(4.0), new Double(↵

3

        ↵

3

    5.0), ↵

4

                    new Double(4.5), new Double(-0.5), new Double(5.5),↵

4

                    new Double(6.0), new Double(7.0), new Double(8.0),↵

5

                        null), "S1", "C1");↵

5

                    new ArrayList()), "ROW1", "COLUMN1");↵

6

                CategoryPlot plot = new CategoryPlot(dataset,↵

6

            ↵

7

                        new CategoryAxis("Category"), new NumberAxis("Value"),↵

8

                        new BoxAndWhiskerRenderer());

7

    assertTrue(d1.equals(d2));

See real code fragment |  | See real code fragment

Summary
Number of common nesting structure subtrees | 1
Number of refactorable cases | 0
Number of non-refactorable cases | 1
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.0
Clones location | Clones are in different classes having the same super class
Number of node comparisons | 4

1. {Non-refactorable}

   Mapping Summary
   Number of mapped statements | 1
   Number of unmapped statements in the first code fragment | 1
   Number of unmapped statements in the second code fragment | 1
   Time elapsed for statement mapping (ms) | 0.0
   Clone type | Type 3

   Mapped Statements
   ID | Statement |  | ID | Statement
   --- | --- | --- | --- | ---

   4

       d2.add(new BoxAndWhiskerItem(new Double(1.0), new Double(2.0), new Double(3.0), new Double(4.0), new Double(5.0), new Double(6.0), new Double(7.0), new Double(8.0), new ArrayList()), "ROW1", "COLUMN1");

   4

       dataset.add(new BoxAndWhiskerItem(new Double(1.0), new Double(2.0), new Double(0.0), new Double(4.0), new Double(0.5), new Double(4.5), new Double(-0.5), new Double(5.5), null), "S1", "C1");

   4 | dataset.add(new BoxAndWhiskerItem(new Double(1.0), new Double(2.0), new Double(0.0), new Double(4.0), new Double(0.5), new Double(4.5), new Double(-0.5), new Double(5.5), null), "S1", "C1");
   5 | assertTrue(d1.equals(d2));

   Differences
   Expression1 | Expression2 | Difference
   --- | --- | ---
   add | assertTrue | METHOD_INVOCATION_NAME_MISMATCH
   dataset.add(new BoxAndWhiskerItem(new Double(1.0),new Double(2.0),new Double(0.0),new Double(4.0),new Double(0.5),new Double(4.5),new Double(-0.5),new Double(5.5),null),"S1","C1") | assertTrue(d1.equals(d2)) | ARGUMENT_NUMBER_MISMATCH
   dataset |  | MISSING_METHOD_INVOCATION_EXPRESSION

   Preondition Violations
   Expression dataset.add(new BoxAndWhiskerItem(new Double(1.0),new Double(2.0),new Double(0.0),new Double(4.0),new Double(0.5),new Double(4.5),new Double(-0.5),new Double(5.5),null),"S1","C1") is a void method call, and thus it cannot be parameterized
   Expression assertTrue(d1.equals(d2)) is a void method call, and thus it cannot be parameterized
   Expression dataset.add(new BoxAndWhiskerItem(new Double(1.0),new Double(2.0),new Double(0.0),new Double(4.0),new Double(0.5),new Double(4.5),new Double(-0.5),new Double(5.5),null),"S1","C1") is a void method call, and thus it cannot be parameterized
   Expression assertTrue(d1.equals(d2)) is a void method call, and thus it cannot be parameterized

   5

       assertTrue(d1.equals(d2));

   Precondition Violations (4)
   Row | Violation
   --- | ---
   1 | Expression dataset.add(new BoxAndWhiskerItem(new Double(1.0),new Double(2.0),new Double(0.0),new Double(4.0),new Double(0.5),new Double(4.5),new Double(-0.5),new Double(5.5),null),"S1","C1") is a void method call, and thus it cannot be parameterized
   2 | Expression assertTrue(d1.equals(d2)) is a void method call, and thus it cannot be parameterized
   3 | Expression dataset.add(new BoxAndWhiskerItem(new Double(1.0),new Double(2.0),new Double(0.0),new Double(4.0),new Double(0.5),new Double(4.5),new Double(-0.5),new Double(5.5),null),"S1","C1") is a void method call, and thus it cannot be parameterized
   4 | Expression assertTrue(d1.equals(d2)) is a void method call, and thus it cannot be parameterized