mirror of
https://github.com/kyverno/kyverno.git
synced 2025-03-31 03:45:17 +00:00
update files to support testing
This commit is contained in:
parent
6b91ce18d2
commit
b68745e806
3 changed files with 56 additions and 0 deletions
20
examples/generate/resources/configMap.yaml
Normal file
20
examples/generate/resources/configMap.yaml
Normal file
|
@ -0,0 +1,20 @@
|
|||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: game-config
|
||||
namespace: default
|
||||
labels:
|
||||
originalLabel : isHere
|
||||
data:
|
||||
ui.properties : |
|
||||
color.good=green
|
||||
color.bad=red
|
||||
|
||||
game.properties : |
|
||||
enemies=predators
|
||||
lives=3
|
||||
|
||||
configmap.data: |
|
||||
ns=default
|
||||
labels=originalLabel
|
||||
labelscount=1
|
7
examples/generate/resources/namespace.yaml
Normal file
7
examples/generate/resources/namespace.yaml
Normal file
|
@ -0,0 +1,7 @@
|
|||
kind: Namespace
|
||||
apiVersion: v1
|
||||
metadata:
|
||||
name: "ns2"
|
||||
labels:
|
||||
LabelForSelector : "namespace2"
|
||||
|
29
examples/generate/testScenarios.yaml
Normal file
29
examples/generate/testScenarios.yaml
Normal file
|
@ -0,0 +1,29 @@
|
|||
# input
|
||||
policy: basic-policy
|
||||
resource: ns2
|
||||
initResources:
|
||||
# expected
|
||||
mutation:
|
||||
reason: Success
|
||||
validation:
|
||||
reason: Success
|
||||
---
|
||||
# input
|
||||
policy: zk-kafka-address
|
||||
resource: ns2
|
||||
initResources:
|
||||
# expected
|
||||
mutation:
|
||||
reason: Success
|
||||
validation:
|
||||
reason: Failed
|
||||
---
|
||||
# input
|
||||
policy: default
|
||||
resource: ns2
|
||||
initResources:
|
||||
# expected
|
||||
mutation:
|
||||
reason: Success
|
||||
validation:
|
||||
reason: Failed
|
Loading…
Add table
Reference in a new issue