diff --git a/rules/ingress-and-egress-blocked/test/default-policy/expected.json b/rules/ingress-and-egress-blocked/test/default-policy/expected.json new file mode 100644 index 000000000..fe51488c7 --- /dev/null +++ b/rules/ingress-and-egress-blocked/test/default-policy/expected.json @@ -0,0 +1 @@ +[] diff --git a/rules/ingress-and-egress-blocked/test/default-policy/input/networkpolicy.yaml b/rules/ingress-and-egress-blocked/test/default-policy/input/networkpolicy.yaml new file mode 100644 index 000000000..8d9a12bb3 --- /dev/null +++ b/rules/ingress-and-egress-blocked/test/default-policy/input/networkpolicy.yaml @@ -0,0 +1,10 @@ +apiVersion: networking.k8s.io/v1 +kind: NetworkPolicy +metadata: + name: default-deny-all + namespace: my-ns +spec: + podSelector: {} + policyTypes: + - Ingress + - Egress diff --git a/rules/ingress-and-egress-blocked/test/default-policy/input/pod.yaml b/rules/ingress-and-egress-blocked/test/default-policy/input/pod.yaml new file mode 100644 index 000000000..78efe1dd9 --- /dev/null +++ b/rules/ingress-and-egress-blocked/test/default-policy/input/pod.yaml @@ -0,0 +1,17 @@ +apiVersion: v1 +kind: Pod +metadata: + name: test + namespace: my-ns +spec: + containers: + - args: + - server + env: + - name: BASE_HREF + value: /argo/ + image: test:latest + name: test + imagePullPolicy: Never + - name : test2 + image : test