1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2025-03-30 19:35:06 +00:00
kyverno/test/cli/test/jmespath-brackets/kyverno-test.yaml
Charles-Edouard Brétéché dbad967150
fix: namespace in kyverno-test.yaml seems to have no effect in case of exclude (#8354)
* fix: namespace in kyverno-test.yaml seems to have no effect in case of exclude

Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>

* fix tests

Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>

* unit tests

Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>

---------

Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
2023-09-12 14:33:26 +00:00

32 lines
583 B
YAML

name: test-preconditions
policies:
- policy.yaml
resources:
- resources.yaml
results:
- kind: Pod
policy: default/test-jmespath
resources:
- test-valid1
- test-valid2
- test-valid3
result: pass
rule: test-jmespath
- kind: Pod
policy: default/test-jmespath
resources:
- test-invalid
result: fail
rule: test-jmespath
- kind: Namespace
policy: namespace-validation
resources:
- test-invalid
result: fail
rule: namespace-validation
- kind: Namespace
policy: namespace-validation
resources:
- test-valid
result: pass
rule: namespace-validation