Skip to content

Commit ef838fc

Browse files
authored
Merge pull request kubernetes#131054 from jsturtevant/fix-up-ginkgo-skips
[sig-windows] Ginkgo skip needs to run inside leaf node otherwise it panics
2 parents bcea7a1 + 2073252 commit ef838fc

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

test/e2e/common/node/security_context.go

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,9 @@ var _ = SIGDescribe("Security Context", func() {
6666
})
6767

6868
ginkgo.Context("When creating a pod with HostUsers", func() {
69-
e2eskipper.SkipIfNodeOSDistroIs("windows")
69+
ginkgo.BeforeEach(func() {
70+
e2eskipper.SkipIfNodeOSDistroIs("windows")
71+
})
7072

7173
containerName := "userns-test"
7274
makePod := func(hostUsers bool) *v1.Pod {
@@ -959,7 +961,9 @@ var _ = SIGDescribe("Security Context", func() {
959961
})
960962

961963
var _ = SIGDescribe("User Namespaces for Pod Security Standards [LinuxOnly]", func() {
962-
e2eskipper.SkipIfNodeOSDistroIs("windows")
964+
ginkgo.BeforeEach(func() {
965+
e2eskipper.SkipIfNodeOSDistroIs("windows")
966+
})
963967

964968
f := framework.NewDefaultFramework("user-namespaces-pss-test")
965969
f.NamespacePodSecurityLevel = admissionapi.LevelRestricted

0 commit comments

Comments
 (0)