Skip to content

Fix image name and operating_system name edge case error

Sashi Kumar Kumaresan requested to merge sk/fix-edge-cases into master

This MR fixes:

  • When location['image'] is 'alpine:latest' current logic set the location['image'] as ['alpine:latest'] since named_captures.values returns an array. The first value should be taken in that case.
  • The OS names are fixed and it does not contain special characters (:) for trivy. Grype outputs the os names with the version(centos:8). In order to support both, the regex could be modified to /[a-z]*/.
  • Modifies as_container_scanner shared examples to separate trivy and grype related assertions
Edited by Sashi Kumar Kumaresan

Merge request reports

Loading