Commit cb2865ed authored by Adam Cohen's avatar Adam Cohen

Fix bug in Container Scanning report remediations

- ContainerScanningVulnerability was missing two
  required fields for remediations to work
  properly `target_branch` and `remediations`
parent 3dcc9548
---
title: Fix bug in Container Scanning report remediations
merge_request: 21980
author:
type: fixed
...@@ -9,6 +9,8 @@ module Gitlab ...@@ -9,6 +9,8 @@ module Gitlab
severity severity
identifiers identifiers
links links
remediations
target_branch
].each do |method_name| ].each do |method_name|
define_method(method_name) do define_method(method_name) do
@data[method_name] @data[method_name]
......
...@@ -22,7 +22,7 @@ describe Gitlab::Vulnerabilities::ContainerScanningVulnerability do ...@@ -22,7 +22,7 @@ describe Gitlab::Vulnerabilities::ContainerScanningVulnerability do
let(:vulnerability) { described_class.new(data) } let(:vulnerability) { described_class.new(data) }
where(:getter) do where(:getter) do
%i[severity confidence identifiers links] %i[severity confidence identifiers links target_branch remediations]
end end
with_them do with_them do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment