Merge pull request #120025 from tzneal/remove-legacy-test-dependency

remove the legacy test dependency
This commit is contained in:
Kubernetes Prow Robot 2023-08-17 12:56:28 -07:00 committed by GitHub
commit c18428423a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -27,13 +27,19 @@ import (
v1 "k8s.io/api/core/v1" v1 "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/util/uuid" "k8s.io/apimachinery/pkg/util/uuid"
admissionapi "k8s.io/pod-security-admission/api"
kubeletconfig "k8s.io/kubernetes/pkg/kubelet/apis/config" kubeletconfig "k8s.io/kubernetes/pkg/kubelet/apis/config"
"k8s.io/kubernetes/test/e2e/framework" "k8s.io/kubernetes/test/e2e/framework"
e2eoutput "k8s.io/kubernetes/test/e2e/framework/pod/output" e2eoutput "k8s.io/kubernetes/test/e2e/framework/pod/output"
"k8s.io/kubernetes/test/e2e/node"
admissionapi "k8s.io/pod-security-admission/api"
) )
// SeccompProcStatusField is the field of /proc/$PID/status referencing the seccomp filter type.
const SeccompProcStatusField = "Seccomp:"
// ProcSelfStatusPath is the path to /proc/self/status.
const ProcSelfStatusPath = "/proc/self/status"
// Serial because the test updates kubelet configuration. // Serial because the test updates kubelet configuration.
var _ = SIGDescribe("SeccompDefault [Serial] [Feature:SeccompDefault] [LinuxOnly]", func() { var _ = SIGDescribe("SeccompDefault [Serial] [Feature:SeccompDefault] [LinuxOnly]", func() {
f := framework.NewDefaultFramework("seccompdefault-test") f := framework.NewDefaultFramework("seccompdefault-test")
@ -54,7 +60,7 @@ var _ = SIGDescribe("SeccompDefault [Serial] [Feature:SeccompDefault] [LinuxOnly
{ {
Name: name, Name: name,
Image: busyboxImage, Image: busyboxImage,
Command: []string{"grep", node.SeccompProcStatusField, node.ProcSelfStatusPath}, Command: []string{"grep", SeccompProcStatusField, ProcSelfStatusPath},
SecurityContext: securityContext, SecurityContext: securityContext,
}, },
}, },