From 05eb255ba65043048352a1a26d178306a6e99a51 Mon Sep 17 00:00:00 2001 From: "Jose R. Gonzalez" Date: Fri, 26 Aug 2022 09:54:38 -0500 Subject: [PATCH] check container type for scratch exceptions instead of os_content_type Signed-off-by: Jose R. Gonzalez --- cmd/check_container.go | 2 +- cmd/fakes_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/check_container.go b/cmd/check_container.go index 51fef445..e41e4d67 100644 --- a/cmd/check_container.go +++ b/cmd/check_container.go @@ -157,7 +157,7 @@ func getContainerPolicyExceptions(ctx context.Context, pc pyxisClient) (policy.P return "", fmt.Errorf("could not retrieve project: %w", err) } log.Debugf("Certification project name is: %s", certProject.Name) - if certProject.Container.OsContentType == "scratch" { + if certProject.Container.Type == "scratch" { return policy.PolicyScratch, nil } diff --git a/cmd/fakes_test.go b/cmd/fakes_test.go index f92f4d98..9a246022 100644 --- a/cmd/fakes_test.go +++ b/cmd/fakes_test.go @@ -101,7 +101,7 @@ func gpFuncReturnError(ctx context.Context) (*pyxis.CertProject, error) { func gpFuncReturnScratchException(ctx context.Context) (*pyxis.CertProject, error) { return &pyxis.CertProject{ Container: pyxis.Container{ - OsContentType: "scratch", + Type: "scratch", }, }, nil }