apiVersion: chainsaw.kyverno.io/v1alpha1 kind: Test metadata: creationTimestamp: null name: conditions spec: steps: - name: step-01 try: - apply: file: policy.yaml - name: step-02 try: - apply: file: exception.yaml - finally: - sleep: duration: 5s name: step-03 try: - apply: file: good-deployment.yaml - apply: expect: - check: ($error != null): true file: bad-deployment.yaml