Katello/katello

View on GitHub
webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js

Summary

Maintainability
F
1 wk
Test Coverage

File CVVersionCompare.test.js has 618 lines of code (exceeds 250 allowed). Consider refactoring.
Open

import React from 'react';
import { act, renderWithRedux, patientlyWaitFor, fireEvent } from 'react-testing-lib-wrapper';
import { Route } from 'react-router-dom';
import { head, last } from 'lodash';
import { nockInstance, assertNockRequest, mockAutocomplete } from '../../../../../../test-utils/nockWrapper';

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

      await patientlyWaitFor(() => {
        testConfigThreeContentTypes.forEach(({ name, textQuery }) => {
          expect(queryByText(name)).toBeTruthy();
          textQuery.forEach(query => expect(queryAllByText(query)).toBeTruthy());
        });
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 358..363

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 89.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

      await patientlyWaitFor(() => {
        testConfigAllContentTypes.forEach(({ name, textQuery }) => {
          expect(queryByText(name)).toBeTruthy();
          textQuery.forEach(query => expect(queryAllByText(query)).toBeTruthy());
        });
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 422..427

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 89.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

      await patientlyWaitFor(() => {
        expect(getByLabelText('Select version 12')).toBeInTheDocument();
        expect(getByLabelText('Select version 13')).toBeInTheDocument();
        expect(getByLabelText('compare_two_versions')).toHaveAttribute('disabled');
      });
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 465..469

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 69.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

      await patientlyWaitFor(() => {
        expect(getByLabelText('Select version 15')).toBeInTheDocument();
        expect(getByLabelText('Select version 17')).toBeInTheDocument();
        expect(getByLabelText('compare_two_versions')).toHaveAttribute('disabled');
      });
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 514..518

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 69.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'Container tags',
        countKey: 'docker_tag_count',
        autoCompleteUrl: '/docker_tags/auto_complete_search',
        dataUrl: api.getApiUrl('/docker_tags/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'Module streams',
        countKey: 'module_stream_count',
        autoCompleteUrl: '/module_streams/auto_complete_search',
        dataUrl: api.getApiUrl('/module_streams/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'RPM package groups',
        countKey: 'package_group_count',
        autoCompleteUrl: '/package_groups/auto_complete_search',
        dataUrl: api.getApiUrl('/package_groups/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'Files',
        countKey: 'file_count',
        autoCompleteUrl: '/files/auto_complete_search',
        dataUrl: api.getApiUrl('/files/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'RPM packages',
        countKey: 'rpm_count',
        autoCompleteUrl: '/packages/auto_complete_search',
        dataUrl: api.getApiUrl('/packages/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'Errata',
        countKey: 'erratum_count',
        autoCompleteUrl: '/errata/auto_complete_search',
        dataUrl: api.getApiUrl('/errata/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'RPM packages',
        countKey: 'rpm_count',
        autoCompleteUrl: '/packages/auto_complete_search',
        dataUrl: api.getApiUrl('/packages/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'Files',
        countKey: 'file_count',
        autoCompleteUrl: '/files/auto_complete_search',
        dataUrl: api.getApiUrl('/files/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'Deb packages',
        countKey: 'deb_count',
        autoCompleteUrl: '/debs/auto_complete_search',
        dataUrl: api.getApiUrl('/debs/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'Ansible collections',
        countKey: 'ansible_collection_count',
        autoCompleteUrl: '/ansible_collections/auto_complete_search',
        dataUrl: api.getApiUrl('/ansible_collections/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'RPM packages',
        countKey: 'rpm_count',
        autoCompleteUrl: '/packages/auto_complete_search',
        dataUrl: api.getApiUrl('/packages/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'Errata',
        countKey: 'erratum_count',
        autoCompleteUrl: '/errata/auto_complete_search',
        dataUrl: api.getApiUrl('/errata/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'Files',
        countKey: 'file_count',
        autoCompleteUrl: '/files/auto_complete_search',
        dataUrl: api.getApiUrl('/files/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'Errata',
        countKey: 'erratum_count',
        autoCompleteUrl: '/errata/auto_complete_search',
        dataUrl: api.getApiUrl('/errata/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 170..179
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

      {
        name: 'Python packages',
        countKey: 'python_package_count',
        autoCompleteUrl: '/python_packages/auto_complete_search',
        dataUrl: api.getApiUrl('/python_packages/compare'),
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 100..109
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 110..119
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 120..129
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 130..139
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 140..149
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 150..159
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 160..169
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 180..189
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 202..211
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 212..221
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 222..231
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 259..268
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 281..290
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 291..300
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 115..124
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 125..134
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 135..144
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 145..154
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 155..164
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 165..174
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 175..184
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 185..195
    webpack/scenes/ContentViews/Details/Versions/VersionDetails/__tests__/ContentViewVersionDetails.test.js on lines 196..205

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 67.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

      const {
        queryByText,
        queryAllByText,
        getByLabelText,
        getByText,
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 631..643

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 63.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

      const {
        queryByText,
        queryAllByText,
        getByLabelText,
        getByText,
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 555..567

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 63.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 3 locations. Consider refactoring.
    Open

      {
        name: 'Repositories',
        autoCompleteUrl: '/repositories/auto_complete_search',
        dataUrl: api.getApiUrl('/repositories/compare'),
        data: cvCompareRepositoriesData,
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 91..99
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 193..201

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 62.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 3 locations. Consider refactoring.
    Open

      {
        name: 'Repositories',
        autoCompleteUrl: '/repositories/auto_complete_search',
        dataUrl: api.getApiUrl('/repositories/compare'),
        data: cvCompareRepositoriesData,
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 91..99
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 272..280

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 62.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 3 locations. Consider refactoring.
    Open

      {
        name: 'Repositories',
        autoCompleteUrl: '/repositories/auto_complete_search',
        dataUrl: api.getApiUrl('/repositories/compare'),
        data: cvCompareRepositoriesData,
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 193..201
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 272..280

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 62.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

      const scopeContentTypes = testConfigViewBySame.map(({ dataUrl, data }) =>
        nockInstance.persist().get(dataUrl).query(true).reply(200, data));
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 541..542

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 62.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

      const scopeContentTypes = testConfigViewByDifferent.map(({ dataUrl, data }) =>
        nockInstance.persist().get(dataUrl).query(true).reply(200, data));
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 617..618

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 62.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

      const { queryByText, queryAllByText, getAllByText } = renderWithRedux(
        withCVRoute(<CVVersionCompare
          cvId={4}
          versionIds={versionIdsAllContentTypes}
          versionLabels={versionLabelsAllContentTypes}
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 399..406

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 61.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

      const { queryByText, queryAllByText, getAllByText } = renderWithRedux(
        withCVRoute(<CVVersionCompare
          cvId={4}
          versionIds={versionIdsThreeContentTypes}
          versionLabels={versionLabelsThreeContentTypes}
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 335..342

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 61.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

      const scopeContentTypes = testConfigAllContentTypes.map(({ dataUrl, data }) =>
        nockInstance.get(dataUrl).query(true).reply(200, data));
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 315..316
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 385..386

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 55.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

      const scopeContentTypes = testConfigThreeContentTypes.map(({ dataUrl, data }) =>
        nockInstance.get(dataUrl).query(true).reply(200, data));
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 315..316
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 442..443

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 55.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

      const scopeContentTypes = testConfigAllContentTypes.map(({ dataUrl, data }) =>
        nockInstance.get(dataUrl).query(true).reply(200, data));
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 385..386
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 442..443

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 55.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

      const { getByLabelText, getByText } = renderWithRedux(
        withCVRoute(<ContentViewVersions cvId={4} details={cvDetailsData} />),
        renderOptions,
      );
    webpack/scenes/ContentViews/Details/Filters/__tests__/CVContainerImageFilterContent.test.js on lines 290..294
    webpack/scenes/ContentViews/Details/Filters/__tests__/contentViewFilters.test.js on lines 140..143
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 460..463
    webpack/scenes/ContentViews/Details/Versions/__tests__/contentViewVersions.test.js on lines 88..91
    webpack/scenes/ContentViews/Details/Versions/__tests__/contentViewVersions.test.js on lines 118..121

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 47.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

      const { getByLabelText, getByText } = renderWithRedux(
        withCVRoute(<ContentViewVersions cvId={4} details={cvDetailsData} />),
        renderOptions,
      );
    webpack/scenes/ContentViews/Details/Filters/__tests__/CVContainerImageFilterContent.test.js on lines 290..294
    webpack/scenes/ContentViews/Details/Filters/__tests__/contentViewFilters.test.js on lines 140..143
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 509..512
    webpack/scenes/ContentViews/Details/Versions/__tests__/contentViewVersions.test.js on lines 88..91
    webpack/scenes/ContentViews/Details/Versions/__tests__/contentViewVersions.test.js on lines 118..121

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 47.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 5 locations. Consider refactoring.
    Open

      await patientlyWaitFor(() => {
        expect(getAllByText(`Version ${versionLabelsAllContentTypes.versionOneLabel}`)).toBeTruthy();
      });
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 414..416
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 574..576
    webpack/scenes/ContentViews/Details/Versions/Delete/__tests__/cvVersionRemove.test.js on lines 60..62
    webpack/scenes/ContentViews/Details/Versions/__tests__/contentViewVersions.test.js on lines 73..75

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 47.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 5 locations. Consider refactoring.
    Open

      await patientlyWaitFor(() => {
        expect(getAllByText(`Version ${versionLabelsThreeContentTypes.versionOneLabel}`)).toBeTruthy();
      });
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 350..352
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 574..576
    webpack/scenes/ContentViews/Details/Versions/Delete/__tests__/cvVersionRemove.test.js on lines 60..62
    webpack/scenes/ContentViews/Details/Versions/__tests__/contentViewVersions.test.js on lines 73..75

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 47.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 5 locations. Consider refactoring.
    Open

      await patientlyWaitFor(() => {
        expect(getByText(`Version ${versionLabelsThreeContentTypes.versionOneLabel}`)).toBeTruthy();
      });
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 350..352
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 414..416
    webpack/scenes/ContentViews/Details/Versions/Delete/__tests__/cvVersionRemove.test.js on lines 60..62
    webpack/scenes/ContentViews/Details/Versions/__tests__/contentViewVersions.test.js on lines 73..75

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 47.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 4 locations. Consider refactoring.
    Open

      await patientlyWaitFor(() => {
        expect(getAllByText(`Version ${versionLabelsAllContentTypes.versionTwoLabel}`)).toBeTruthy();
      });
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 418..420
    webpack/scenes/ContentViews/Details/Versions/__tests__/contentViewVersions.test.js on lines 249..251
    webpack/scenes/ContentViews/Details/Versions/__tests__/contentViewVersions.test.js on lines 339..341

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 47.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 4 locations. Consider refactoring.
    Open

      await patientlyWaitFor(() => {
        expect(getAllByText(`Version ${versionLabelsThreeContentTypes.versionTwoLabel}`)).toBeTruthy();
      });
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 354..356
    webpack/scenes/ContentViews/Details/Versions/__tests__/contentViewVersions.test.js on lines 249..251
    webpack/scenes/ContentViews/Details/Versions/__tests__/contentViewVersions.test.js on lines 339..341

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 47.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

      await patientlyWaitFor(() => {
        expect(getByText(`Version ${versionLabelsThreeContentTypes.versionOneLabel}`)).toBeTruthy();
      });
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 578..580
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 651..653

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 45.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

      await patientlyWaitFor(() => {
        expect(getByText(`Version ${versionLabelsThreeContentTypes.versionTwoLabel}`)).toBeTruthy();
      });
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 648..650
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 651..653

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 45.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

      await patientlyWaitFor(() => {
        expect(getByText(`Version ${versionLabelsThreeContentTypes.versionTwoLabel}`)).toBeTruthy();
      });
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 578..580
    webpack/scenes/ContentViews/Details/Versions/Compare/__tests__/CVVersionCompare.test.js on lines 648..650

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 45.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    There are no issues that match your filters.

    Category
    Status