# yaml-language-server: $schema=https://raw.githubusercontent.com/kyverno/chainsaw/main/.schemas/json/test-chainsaw-v1alpha1.json
apiVersion: chainsaw.kyverno.io/v1alpha1
kind: Test
metadata:
  creationTimestamp: null
  name: simple-deployment-not-allowed
spec:
  steps:
    - name: step-00
      try:
        - apply:
            file: 00-install.yaml
        - assert:
            file: 00-assert.yaml
    - name: step-01
      try:
        # we expect none of these resources to be present
        - error:
            resource:
              apiVersion: lifecycle.keptn.sh/v1
              kind: KeptnTask
              metadata:
                namespace: not-allowed-ns-test
        - error:
            resource:
              apiVersion: lifecycle.keptn.sh/v1
              kind: KeptnWorkload
              metadata:
                namespace: not-allowed-ns-test
        - error:
            resource:
              apiVersion: lifecycle.keptn.sh/v1
              kind: KeptnApp
              metadata:
                namespace: not-allowed-ns-test
