mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-06-22 21:49:41 +00:00
tests: k8s-pod-quota.bats allow all policy
Use the "allow all" policy for k8s-pod-quota.bats, instead of relying on the Kata Guest image to use the same policy as its default. Signed-off-by: Dan Mihai <dmihai@microsoft.com>
This commit is contained in:
parent
ba23758a42
commit
3f94e2ee1b
@ -11,6 +11,9 @@ setup() {
|
|||||||
[ "${KATA_HYPERVISOR}" == "fc" ] && skip "test not working see: https://github.com/kata-containers/kata-containers/issues/7873"
|
[ "${KATA_HYPERVISOR}" == "fc" ] && skip "test not working see: https://github.com/kata-containers/kata-containers/issues/7873"
|
||||||
|
|
||||||
get_pod_config_dir
|
get_pod_config_dir
|
||||||
|
|
||||||
|
deployment_yaml="${pod_config_dir}/pod-quota-deployment.yaml"
|
||||||
|
add_allow_all_policy_to_yaml "${deployment_yaml}"
|
||||||
}
|
}
|
||||||
|
|
||||||
@test "Pod quota" {
|
@test "Pod quota" {
|
||||||
@ -25,7 +28,7 @@ setup() {
|
|||||||
--output=yaml | grep 'pods: "2"'
|
--output=yaml | grep 'pods: "2"'
|
||||||
|
|
||||||
# Create deployment
|
# Create deployment
|
||||||
kubectl create -f "${pod_config_dir}/pod-quota-deployment.yaml"
|
kubectl create -f "${deployment_yaml}"
|
||||||
|
|
||||||
# View deployment
|
# View deployment
|
||||||
kubectl wait --for=condition=Available --timeout=$timeout \
|
kubectl wait --for=condition=Available --timeout=$timeout \
|
||||||
@ -39,6 +42,6 @@ teardown() {
|
|||||||
kubectl describe deployment ${deployment_name}
|
kubectl describe deployment ${deployment_name}
|
||||||
|
|
||||||
# Clean-up
|
# Clean-up
|
||||||
kubectl delete -f "${pod_config_dir}/pod-quota-deployment.yaml"
|
kubectl delete -f "${deployment_yaml}"
|
||||||
kubectl delete -f "${pod_config_dir}/resource-quota.yaml"
|
kubectl delete -f "${pod_config_dir}/resource-quota.yaml"
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user