diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-05-03 00:19:21 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-05-03 00:19:21 +0300 |
commit | 90693cc231ba6e1645dc57f2a9111a7b5a5ceae0 (patch) | |
tree | 3b2cffdb40c949b2f061b7fd0f52d3214325cc17 /spec/presenters | |
parent | b9ce0fe1e6311105b7a748126621f9bfbe37fb2e (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/presenters')
-rw-r--r-- | spec/presenters/ci/pipeline_artifacts/code_quality_mr_diff_presenter_spec.rb | 49 |
1 files changed, 5 insertions, 44 deletions
diff --git a/spec/presenters/ci/pipeline_artifacts/code_quality_mr_diff_presenter_spec.rb b/spec/presenters/ci/pipeline_artifacts/code_quality_mr_diff_presenter_spec.rb index 3f40b5469ad..99c82795210 100644 --- a/spec/presenters/ci/pipeline_artifacts/code_quality_mr_diff_presenter_spec.rb +++ b/spec/presenters/ci/pipeline_artifacts/code_quality_mr_diff_presenter_spec.rb @@ -36,24 +36,8 @@ RSpec.describe Ci::PipelineArtifacts::CodeQualityMrDiffPresenter, feature_catego expect(quality_data).to match( files: { "file_a.rb" => [ - { line: 10, - description: "Avoid parameter lists longer than 5 parameters. [12/5]", - severity: "major", - engine_name: "structure", - categories: ["Complexity"], - content: { "body" => "" }, - location: { "lines" => { "begin" => 10, "end" => 10 }, "path" => "file_a.rb" }, - other_locations: [], - type: "issue" }, - { line: 10, - description: "Method `new_array` has 12 arguments (exceeds 4 allowed). Consider refactoring.", - severity: "minor", - engine_name: "structure", - categories: ["Complexity"], - content: { "body" => "" }, - location: { "lines" => { "begin" => 10, "end" => 10 }, "path" => "file_a.rb" }, - other_locations: [], - type: "issue" } + { line: 10, description: "Avoid parameter lists longer than 5 parameters. [12/5]", severity: "major" }, + { line: 10, description: "Method `new_array` has 12 arguments (exceeds 4 allowed). Consider refactoring.", severity: "minor" } ] } ) @@ -67,34 +51,11 @@ RSpec.describe Ci::PipelineArtifacts::CodeQualityMrDiffPresenter, feature_catego expect(quality_data).to match( files: { "file_a.rb" => [ - { line: 10, - description: "Avoid parameter lists longer than 5 parameters. [12/5]", - severity: "major", - engine_name: "structure", - categories: ["Complexity"], - content: { "body" => "" }, - location: { "lines" => { "begin" => 10, "end" => 10 }, "path" => "file_a.rb" }, - other_locations: [], - type: "issue" }, - { line: 10, - description: "Method `new_array` has 12 arguments (exceeds 4 allowed). Consider refactoring.", - severity: "minor", - engine_name: "structure", - categories: ["Complexity"], - content: { "body" => "" }, - location: { "lines" => { "begin" => 10, "end" => 10 }, "path" => "file_a.rb" }, - other_locations: [], - type: "issue" } + { line: 10, description: "Avoid parameter lists longer than 5 parameters. [12/5]", severity: "major" }, + { line: 10, description: "Method `new_array` has 12 arguments (exceeds 4 allowed). Consider refactoring.", severity: "minor" } ], "file_b.rb" => [ - { line: 10, - description: "This cop checks for methods with too many parameters.\nThe maximum number of parameters is configurable.\nKeyword arguments can optionally be excluded from the total count.", - severity: "minor", - engine_name: "rubocop", - categories: ["Complexity"], - content: { "body" => "" }, - location: { "positions" => { "begin" => { "column" => 14, "line" => 10 }, "end" => { "column" => 39, "line" => 10 } }, "path" => "file_b.rb" }, - type: "Issue" } + { line: 10, description: "This cop checks for methods with too many parameters.\nThe maximum number of parameters is configurable.\nKeyword arguments can optionally be excluded from the total count.", severity: "minor" } ] } ) |