Source:
<code>public void test_cpd() { Offset<Double> offset = Offset.offset(0.01d); <START> assertThat(getFileMeasureAsDouble("file1.py","duplicated_lines")).isEqualTo(27.0d, offset); <END> assertThat(getFileMeasureAsDouble("file1.py","duplicated_blocks")).isEqualTo(1.0d, offset); assertThat(getFileMeasureAsDouble("file1.py","duplicated_files")).isEqualTo(1.0d, offset); assertThat(getFileMeasureAsDouble("file1.py","duplicated_lines_density")).isEqualTo(96.4d, offset); assertThat(getFileMeasureAsDouble("file2.py","duplicated_lines")).isEqualTo(27.0d, offset); assertThat(getFileMeasureAsDouble("file2.py","duplicated_blocks")).isEqualTo(1.0d, offset); assertThat(getFileMeasureAsDouble("file2.py","duplicated_files")).isEqualTo(1.0d, offset); assertThat(getFileMeasureAsDouble("file2.py","duplicated_lines_density")).isEqualTo(96.4d, offset); assertThat(getFileMeasureAsDouble("file3.py","duplicated_lines")).isEqualTo(0.0d, offset); assertThat(getFileMeasureAsDouble("file3.py","duplicated_blocks")).isEqualTo(0.0d, offset); assertThat(getFileMeasureAsDouble("file3.py","duplicated_files")).isEqualTo(0.0d, offset); assertThat(getFileMeasureAsDouble("file3.py","duplicated_lines_density")).isEqualTo(0.0d, offset); assertThat(getMeasureAsDouble(PROJECT_KEY, "duplicated_lines")).isEqualTo(54.0d, offset); assertThat(getMeasureAsDouble(PROJECT_KEY, "duplicated_blocks")).isEqualTo(2.0d, offset); assertThat(getMeasureAsDouble(PROJECT_KEY, "duplicated_files")).isEqualTo(2.0d, offset); assertThat(getMeasureAsDouble(PROJECT_KEY, "duplicated_lines_density")).isEqualTo(63.5d, offset); }</code><technical_language>Pretty nice work ITs! hit hard "constant duplication" rule this code is analyzed</technical_language>

Target:
public void test_cpd() { Offset<Double> offset = Offset.offset(0.01d); assertThat(getMeasureAsDouble(FILE_1_KEY, DUPLICATED_LINES)).isEqualTo(27.0d, offset); assertThat(getMeasureAsDouble(FILE_1_KEY, DUPLICATED_BLOCKS)).isEqualTo(1.0d, offset); assertThat(getMeasureAsDouble(FILE_1_KEY, DUPLICATED_FILES)).isEqualTo(1.0d, offset); assertThat(getMeasureAsDouble(FILE_1_KEY, DUPLICATED_LINES_DENSITY)).isEqualTo(93.1d, offset); assertThat(getMeasureAsDouble(FILE_2_KEY, DUPLICATED_LINES)).isEqualTo(27.0d, offset); assertThat(getMeasureAsDouble(FILE_2_KEY, DUPLICATED_BLOCKS)).isEqualTo(1.0d, offset); assertThat(getMeasureAsDouble(FILE_2_KEY, DUPLICATED_FILES)).isEqualTo(1.0d, offset); assertThat(getMeasureAsDouble(FILE_2_KEY, DUPLICATED_LINES_DENSITY)).isEqualTo(90.0d, offset); assertThat(getMeasureAsDouble(FILE_3_KEY, DUPLICATED_LINES)).isEqualTo(0.0d, offset); assertThat(getMeasureAsDouble(FILE_3_KEY, DUPLICATED_BLOCKS)).isEqualTo(0.0d, offset); assertThat(getMeasureAsDouble(FILE_3_KEY, DUPLICATED_FILES)).isEqualTo(0.0d, offset); assertThat(getMeasureAsDouble(FILE_3_KEY, DUPLICATED_LINES_DENSITY)).isEqualTo(0.0d, offset); assertThat(getMeasureAsDouble(PROJECT_KEY, DUPLICATED_LINES)).isEqualTo(54.0d, offset); assertThat(getMeasureAsDouble(PROJECT_KEY, DUPLICATED_BLOCKS)).isEqualTo(2.0d, offset); assertThat(getMeasureAsDouble(PROJECT_KEY, DUPLICATED_FILES)).isEqualTo(2.0d, offset); assertThat(getMeasureAsDouble(PROJECT_KEY, DUPLICATED_LINES_DENSITY)).isEqualTo(61.4d, offset); }