From 92621265b986d385dc85002c07c5c45ede38f505 Mon Sep 17 00:00:00 2001 From: Marcelo Guerrero Date: Sat, 1 Jul 2023 02:01:07 +0200 Subject: [PATCH] Disable webhooks in api server of envtest The operatorconfig controller tests were broken due to the validating webhook. Signed-off-by: Marcelo Guerrero --- controllers/suite_test.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/controllers/suite_test.go b/controllers/suite_test.go index 9bd666ae7..3d534695f 100644 --- a/controllers/suite_test.go +++ b/controllers/suite_test.go @@ -75,6 +75,8 @@ var _ = BeforeSuite(func(done Done) { ErrorIfCRDPathMissing: true, } + testEnv.ControlPlane.GetAPIServer().Configure().Set("disable-admission-plugins", "MutatingAdmissionWebhook", "ValidatingAdmissionWebhook") + cfg, err := testEnv.Start() Expect(err).NotTo(HaveOccurred()) Expect(cfg).NotTo(BeNil())