mirror of
https://github.com/kyverno/kyverno.git
synced 2025-03-09 01:16:55 +00:00
* chore: bump chainsaw Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * more template use Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * v0.2.10 Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * go mod Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> --------- Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> |
||
---|---|---|
.. | ||
chainsaw-test.yaml | ||
kyverno-configmap-assert.yaml | ||
policy-assert.yaml | ||
policy.yaml | ||
README.md | ||
resource-assert.yaml | ||
resource.yaml |
Description
This test patches kyverno
configmap in kyverno
namespace with generateSuccessEvents
set to false
Then it creates a policy and a resource.
The resource is expected to be accepted.
A PolicyApplied
event with message ConfigMap default/foo: pass
from object policy/require-labels
should not be created as generateSuccessEvents
config is set to false
Steps
- Patch
kyverno
configmap inkyverno
namespace withgenerateSuccessEvents
set tofalse
- Create a policy
- Assert the policy becomes ready
- Create a resource
- Assert there is no
PolicyApplied
event with messageConfigMap default/foo: pass
is created via script - Exit the script with code
1
if it returns an error