mirror of
https://github.com/kyverno/kyverno.git
synced 2025-03-09 09:26:54 +00:00
40 lines
817 B
YAML
Executable file
40 lines
817 B
YAML
Executable file
apiVersion: chainsaw.kyverno.io/v1alpha1
|
|
kind: Test
|
|
metadata:
|
|
name: report-deletion
|
|
spec:
|
|
steps:
|
|
- name: step-00
|
|
try:
|
|
- apply:
|
|
file: ns.yaml
|
|
- assert:
|
|
file: ns.yaml
|
|
- name: step-01
|
|
try:
|
|
- apply:
|
|
file: pod.yaml
|
|
- assert:
|
|
file: pod.yaml
|
|
- name: create policy
|
|
use:
|
|
template: ../../_step-templates/create-policy.yaml
|
|
with:
|
|
bindings:
|
|
- name: file
|
|
value: policy.yaml
|
|
- name: wait policy ready
|
|
use:
|
|
template: ../../_step-templates/cluster-policy-ready.yaml
|
|
with:
|
|
bindings:
|
|
- name: name
|
|
value: cpol-match-conditions-userinfo
|
|
- name: step-03
|
|
try:
|
|
- error:
|
|
file: report-error-1.yaml
|
|
- name: step-04
|
|
try:
|
|
- error:
|
|
file: report-error-2.yaml
|