From b5c25c389a38cd6171d76b6bd4dc8a3fcf648783 Mon Sep 17 00:00:00 2001 From: andyzhangx Date: Wed, 21 Dec 2022 06:45:42 +0000 Subject: [PATCH] test: fix PodSecurity issue --- .github/workflows/static.yaml | 2 +- test/e2e/dynamic_provisioning_test.go | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/static.yaml b/.github/workflows/static.yaml index 2bd5e9e51b9..fc716ca3b74 100644 --- a/.github/workflows/static.yaml +++ b/.github/workflows/static.yaml @@ -16,4 +16,4 @@ jobs: uses: golangci/golangci-lint-action@v3 with: version: v1.48 - args: -E=gofmt,deadcode,unused,varcheck,ineffassign,revive,misspell,exportloopref,asciicheck,bodyclose,depguard,dogsled,durationcheck,errname,forbidigo -D=staticcheck --timeout=30m0s + args: -E=gofmt,deadcode,unused,varcheck,ineffassign,revive,misspell,exportloopref,asciicheck,bodyclose,contextcheck,depguard,dogsled,durationcheck,errname,forbidigo -D=staticcheck --timeout=30m0s diff --git a/test/e2e/dynamic_provisioning_test.go b/test/e2e/dynamic_provisioning_test.go index a2074ba2260..806a49a7516 100644 --- a/test/e2e/dynamic_provisioning_test.go +++ b/test/e2e/dynamic_provisioning_test.go @@ -27,10 +27,12 @@ import ( clientset "k8s.io/client-go/kubernetes" _ "k8s.io/client-go/plugin/pkg/client/auth/gcp" "k8s.io/kubernetes/test/e2e/framework" + admissionapi "k8s.io/pod-security-admission/api" ) var _ = ginkgo.Describe("Dynamic Provisioning", func() { f := framework.NewDefaultFramework("smb") + f.NamespacePodSecurityEnforceLevel = admissionapi.LevelPrivileged var ( cs clientset.Interface