From 39805822fc42226a2acf4817475c343372fdfd9e Mon Sep 17 00:00:00 2001 From: Dan Mihai Date: Tue, 2 Apr 2024 16:18:31 +0000 Subject: [PATCH] tests: k8s: reduce policy testing complexity Don't add the "allow all" policy to all the test YAML files anymore. After this change, the k8s tests assume that all the Kata CI Guest rootfs image files either: - Don't support Agent Policy at all, or - Include an "allow all" default policy. This relience/assumption will be addressed in a future commit. Fixes: #9395 Signed-off-by: Dan Mihai --- tests/integration/kubernetes/run_kubernetes_tests.sh | 9 --------- 1 file changed, 9 deletions(-) diff --git a/tests/integration/kubernetes/run_kubernetes_tests.sh b/tests/integration/kubernetes/run_kubernetes_tests.sh index a55d13e155..1f36a187c6 100755 --- a/tests/integration/kubernetes/run_kubernetes_tests.sh +++ b/tests/integration/kubernetes/run_kubernetes_tests.sh @@ -131,14 +131,6 @@ add_policy_to_yaml() { esac } -add_policy_to_successful_tests() { - info "Add policy to test YAML files" - for K8S_TEST_YAML in runtimeclass_workloads_work/*.yaml - do - add_policy_to_yaml "${K8S_TEST_YAML}" - done -} - test_successful_actions() { info "Test actions that must be successful" for K8S_TEST_ENTRY in ${K8S_TEST_UNION[@]} @@ -169,7 +161,6 @@ fi if policy_tests_enabled; then ensure_yq run_policy_specific_tests - add_policy_to_successful_tests else info "Policy tests are disabled on this platform" fi