From 99146756749b8e457d8f573cbc0e0208fa59e560 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Charles-Edouard=20Br=C3=A9t=C3=A9ch=C3=A9?= Date: Thu, 3 Oct 2024 17:08:36 +0200 Subject: [PATCH] chore: use more chainsaw step templates (#11313) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Charles-Edouard Brétéché --- .github/workflows/conformance.yaml | 2 +- .../first-rule-is-foreach/chainsaw-test.yaml | 20 ++++++++++++----- .../first-rule-is-foreach/policy-assert.yaml | 9 -------- .../cascading/no-foreach/chainsaw-test.yaml | 20 ++++++++++++----- .../cascading/no-foreach/policy-assert.yaml | 9 -------- .../two-foreach-rules/chainsaw-test.yaml | 20 ++++++++++++----- .../two-foreach-rules/policy-assert.yaml | 9 -------- .../cascading-mutation/chainsaw-test.yaml | 20 ++++++++++++----- .../cascading-mutation/policy-ready.yaml | 9 -------- .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 22 +++++++++++++------ ...p-04-apply-1-1.yaml => policy-update.yaml} | 0 ...saw-step-01-apply-1-1.yaml => policy.yaml} | 0 .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-assert.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-assert.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-assert.yaml | 4 ---- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-assert.yaml | 9 -------- .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- ...saw-step-01-apply-1-1.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- ...saw-step-01-apply-1-1.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../basic-check-output/chainsaw-test.yaml | 20 ++++++++++++----- ...saw-step-01-apply-1-1.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 18 +++++++++++---- ...saw-step-01-apply-1-2.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../background-false/chainsaw-test.yaml | 18 +++++++++++---- ...saw-step-01-apply-1-2.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 18 +++++++++++---- ...saw-step-01-apply-1-3.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 18 +++++++++++---- ...saw-step-01-apply-1-3.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 18 +++++++++++---- ...saw-step-01-apply-1-3.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../existing/basic-create/chainsaw-test.yaml | 18 +++++++++++---- ...saw-step-01-apply-1-3.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 18 +++++++++++---- ...saw-step-01-apply-1-4.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../existing/basic-delete/chainsaw-test.yaml | 18 +++++++++++---- ...saw-step-01-apply-1-4.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 18 +++++++++++---- ...saw-step-01-apply-1-4.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../existing/basic-update/chainsaw-test.yaml | 18 +++++++++++---- ...saw-step-01-apply-1-4.yaml => policy.yaml} | 0 .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-ready.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-ready.yaml | 9 -------- .../chainsaw-test.yaml | 22 ++++++++++++------- .../policy-assert.yaml | 5 ----- .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 18 +++++++++++---- ...saw-step-01-apply-1-5.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 18 +++++++++++---- ...saw-step-01-apply-1-5.yaml => policy.yaml} | 0 .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-ready.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-ready.yaml | 9 -------- .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 21 +++++++++++++----- ...saw-step-01-apply-1-1.yaml => policy.yaml} | 0 .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 20 +++++++++++++---- ...saw-step-01-apply-1-2.yaml => policy.yaml} | 0 .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-assert.yaml | 9 -------- .../namespaceselector/chainsaw-test.yaml | 20 ++++++++++++----- .../namespaceselector/policy-assert.yaml | 9 -------- .../chainsaw-step-02-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- ...saw-step-02-apply-1-1.yaml => policy.yaml} | 0 .../chainsaw-step-02-assert-1-1.yaml | 9 -------- .../basic-create-policy/chainsaw-test.yaml | 20 ++++++++++++----- ...saw-step-02-apply-1-1.yaml => policy.yaml} | 0 .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-ready.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-ready.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-assert.yaml | 9 -------- .../namespaceselector/chainsaw-test.yaml | 20 ++++++++++++----- .../namespaceselector/policy-assert.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-ready.yaml | 9 -------- .../existing/preconditions/chainsaw-test.yaml | 20 ++++++++++++----- .../existing/preconditions/policy-ready.yaml | 9 -------- .../target-context/chainsaw-test.yaml | 20 ++++++++++++----- .../target-context/policy-assert.yaml | 9 -------- .../target-preconditions/chainsaw-test.yaml | 20 ++++++++++++----- .../target-preconditions/policy-assert.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-assert.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-assert.yaml | 9 -------- .../chainsaw-step-01-assert-1-1.yaml | 9 -------- .../mutate-node-status/chainsaw-test.yaml | 20 ++++++++++++----- ...saw-step-01-apply-1-1.yaml => policy.yaml} | 0 .../chainsaw-test.yaml | 16 ++++++++++++-- ...saw-step-01-apply-1-6.yaml => policy.yaml} | 0 .../e2e/emit-warning/chainsaw-test.yaml | 20 ++++++++++++----- .../e2e/emit-warning/policy-assert.yaml | 4 ---- .../chainsaw-step-02-assert-1-1.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- ...saw-step-02-apply-1-1.yaml => policy.yaml} | 0 .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-ready.yaml | 9 -------- .../e2e/jmespath-logic/chainsaw-test.yaml | 20 ++++++++++++----- .../e2e/jmespath-logic/policy-one-ready.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-ready.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-ready.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../patchesJson6902-replace/policy-ready.yaml | 9 -------- .../patchesjson6902-simple/chainsaw-test.yaml | 20 ++++++++++++----- .../patchesjson6902-simple/policy-ready.yaml | 9 -------- .../e2e/simple-conditional/chainsaw-test.yaml | 20 ++++++++++++----- .../e2e/simple-conditional/policy-ready.yaml | 9 -------- .../e2e/variables-in-keys/chainsaw-test.yaml | 20 ++++++++++++----- .../e2e/variables-in-keys/policy-ready.yaml | 9 -------- .../chainsaw-test.yaml | 22 +++++++++++++------ .../policy-assert.yaml | 9 -------- .../validation/auth-check/chainsaw-test.yaml | 22 ++++++++++++++----- .../validation/auth-check/policy-assert.yaml | 10 --------- .../foreach/add-and-remove/chainsaw-test.yaml | 20 ++++++++++++----- .../foreach/add-and-remove/policy-assert.yaml | 9 -------- .../foreach/remove-and-add/chainsaw-test.yaml | 20 ++++++++++++----- .../foreach/remove-and-add/policy-assert.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-assert.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-assert.yaml | 9 -------- .../k10-minimum-retention/chainsaw-test.yaml | 20 ++++++++++++----- .../k10-minimum-retention/policy-ready.yaml | 9 -------- .../remove-all-env-vars/chainsaw-test.yaml | 20 ++++++++++++----- .../remove-all-env-vars/policy-assert.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-assert.yaml | 9 -------- .../chainsaw-test.yaml | 20 ++++++++++++----- .../policy-assert.yaml | 9 -------- 158 files changed, 946 insertions(+), 958 deletions(-) delete mode 100644 test/conformance/chainsaw/mutate/cascading/first-rule-is-foreach/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/cascading/no-foreach/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/cascading/two-foreach-rules/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/cornercases/cascading-mutation/policy-ready.yaml delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/{chainsaw-step-04-apply-1-1.yaml => policy-update.yaml} (100%) rename test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/{chainsaw-step-01-apply-1-1.yaml => policy.yaml} (100%) delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/cornercases/jmespath-with-special-chars/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-using-default-context/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-with-404-api-call/policy-assert.yaml delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/cornercases/trigger-name-exceeds-63-characters/policy-assert.yaml delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing-deprecated/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing-deprecated/{chainsaw-step-01-apply-1-1.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing/{chainsaw-step-01-apply-1-1.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/basic-check-output/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/basic-check-output/{chainsaw-step-01-apply-1-1.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false(deprecated)/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false(deprecated)/{chainsaw-step-01-apply-1-2.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false/{chainsaw-step-01-apply-1-2.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create(deprecated)/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create(deprecated)/{chainsaw-step-01-apply-1-3.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902(deprecated)/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902(deprecated)/{chainsaw-step-01-apply-1-3.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902/{chainsaw-step-01-apply-1-3.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create/{chainsaw-step-01-apply-1-3.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete(deprecated)/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete(deprecated)/{chainsaw-step-01-apply-1-4.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete/{chainsaw-step-01-apply-1-4.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update(deprecated)/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update(deprecated)/{chainsaw-step-01-apply-1-4.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update/{chainsaw-step-01-apply-1-4.yaml => policy.yaml} (100%) delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace(deprecated)/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/descending-patchJson6902/policy-assert.yaml delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude(deprecated)/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude(deprecated)/{chainsaw-step-01-apply-1-5.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude/{chainsaw-step-01-apply-1-5.yaml => policy.yaml} (100%) delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources(deprecated)/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources/policy-ready.yaml delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-existing-node-status/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-existing-node-status/{chainsaw-step-01-apply-1-1.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-pod-on-binding-request/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-pod-on-binding-request/{chainsaw-step-01-apply-1-2.yaml => policy.yaml} (100%) delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector(deprecated)/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector/policy-assert.yaml delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy(deprecated)/chainsaw-step-02-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy(deprecated)/{chainsaw-step-02-apply-1-1.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy/chainsaw-step-02-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy/{chainsaw-step-02-apply-1-1.yaml => policy.yaml} (100%) delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-configurations-for-mutate-existing/policy-ready.yaml delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-mutate-existing-values/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector(deprecated)/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions(deprecated)/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-context/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-preconditions/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check(deprecated)/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check/policy-assert.yaml delete mode 100755 test/conformance/chainsaw/mutate/clusterpolicy/standard/mutate-node-status/chainsaw-step-01-assert-1-1.yaml rename test/conformance/chainsaw/mutate/clusterpolicy/standard/mutate-node-status/{chainsaw-step-01-apply-1-1.yaml => policy.yaml} (100%) rename test/conformance/chainsaw/mutate/clusterpolicy/standard/userInfo-roles-clusterRoles/{chainsaw-step-01-apply-1-6.yaml => policy.yaml} (100%) delete mode 100644 test/conformance/chainsaw/mutate/e2e/emit-warning/policy-assert.yaml delete mode 100755 test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-context/chainsaw-step-02-assert-1-1.yaml rename test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-context/{chainsaw-step-02-apply-1-1.yaml => policy.yaml} (100%) delete mode 100644 test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-preconditions/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/e2e/jmespath-logic/policy-one-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global-addifnotpresent/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/e2e/patchesJson6902-replace/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/e2e/patchesjson6902-simple/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/e2e/simple-conditional/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/e2e/variables-in-keys/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/policy/cornercases/foreach-remove-elements/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/policy/standard/existing/validation/auth-check/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/refactor/foreach/add-and-remove/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/refactor/foreach/remove-and-add/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-ascending-order/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-descending-order/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/refactor/k10-minimum-retention/policy-ready.yaml delete mode 100644 test/conformance/chainsaw/mutate/refactor/nested-foreach/remove-all-env-vars/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-ascending-order/policy-assert.yaml delete mode 100644 test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-descending-order/policy-assert.yaml diff --git a/.github/workflows/conformance.yaml b/.github/workflows/conformance.yaml index 3979bc318b..83bf025556 100644 --- a/.github/workflows/conformance.yaml +++ b/.github/workflows/conformance.yaml @@ -59,7 +59,7 @@ jobs: uses: ./.github/actions/setup-build-env timeout-minutes: 10 with: - free-disk-space: true + free-disk-space: false - name: Build CLI shell: bash run: | diff --git a/test/conformance/chainsaw/mutate/cascading/first-rule-is-foreach/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/cascading/first-rule-is-foreach/chainsaw-test.yaml index 8452dc9340..664f61dc69 100755 --- a/test/conformance/chainsaw/mutate/cascading/first-rule-is-foreach/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/cascading/first-rule-is-foreach/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: first-rule-is-foreach spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: mutate-chain - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/cascading/first-rule-is-foreach/policy-assert.yaml b/test/conformance/chainsaw/mutate/cascading/first-rule-is-foreach/policy-assert.yaml deleted file mode 100644 index 607796aab5..0000000000 --- a/test/conformance/chainsaw/mutate/cascading/first-rule-is-foreach/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: mutate-chain -status: - conditions: - - reason: Succeeded - status: 'True' - type: Ready diff --git a/test/conformance/chainsaw/mutate/cascading/no-foreach/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/cascading/no-foreach/chainsaw-test.yaml index a218b723cf..fafecb9e9b 100755 --- a/test/conformance/chainsaw/mutate/cascading/no-foreach/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/cascading/no-foreach/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: no-foreach spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: mutate-chain - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/cascading/no-foreach/policy-assert.yaml b/test/conformance/chainsaw/mutate/cascading/no-foreach/policy-assert.yaml deleted file mode 100644 index 607796aab5..0000000000 --- a/test/conformance/chainsaw/mutate/cascading/no-foreach/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: mutate-chain -status: - conditions: - - reason: Succeeded - status: 'True' - type: Ready diff --git a/test/conformance/chainsaw/mutate/cascading/two-foreach-rules/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/cascading/two-foreach-rules/chainsaw-test.yaml index 2c48fca620..8fd98d04f9 100755 --- a/test/conformance/chainsaw/mutate/cascading/two-foreach-rules/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/cascading/two-foreach-rules/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: two-foreach-rules spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: mutate-chain - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/cascading/two-foreach-rules/policy-assert.yaml b/test/conformance/chainsaw/mutate/cascading/two-foreach-rules/policy-assert.yaml deleted file mode 100644 index 607796aab5..0000000000 --- a/test/conformance/chainsaw/mutate/cascading/two-foreach-rules/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: mutate-chain -status: - conditions: - - reason: Succeeded - status: 'True' - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/cascading-mutation/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/cascading-mutation/chainsaw-test.yaml index 7abcb54318..9e9d97159e 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/cascading-mutation/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/cascading-mutation/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: cascading-mutation spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: database-protection - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/cascading-mutation/policy-ready.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/cascading-mutation/policy-ready.yaml deleted file mode 100644 index ec1d9487fa..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/cascading-mutation/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: database-protection -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 8150b81d4c..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: propagate-cost-labels-from-namespace -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/chainsaw-test.yaml index 5980ed883e..05dde52006 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: defaulting-namespace-labels spec: steps: - - name: step-01 - try: - - apply: - file: chainsaw-step-01-apply-1-1.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: propagate-cost-labels-from-namespace - name: step-02 try: - script: @@ -23,7 +31,7 @@ spec: - name: step-04 try: - apply: - file: chainsaw-step-04-apply-1-1.yaml + file: policy-update.yaml - name: step-05 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/chainsaw-step-04-apply-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/policy-update.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/chainsaw-step-04-apply-1-1.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/policy-update.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/chainsaw-step-01-apply-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/chainsaw-step-01-apply-1-1.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/cornercases/defaulting-namespace-labels/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/jmespath-with-special-chars/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/jmespath-with-special-chars/chainsaw-test.yaml index 151f49d208..5caeefdcf8 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/jmespath-with-special-chars/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/jmespath-with-special-chars/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: jmespath-with-special-chars spec: steps: - - name: step-00 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: jmespath-with-special-chars-demo - name: step-01 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/jmespath-with-special-chars/policy-assert.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/jmespath-with-special-chars/policy-assert.yaml deleted file mode 100644 index 85dd54eef7..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/jmespath-with-special-chars/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: jmespath-with-special-chars-demo -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-using-default-context/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-using-default-context/chainsaw-test.yaml index ee23242ce8..58ab0be4d0 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-using-default-context/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-using-default-context/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: mutate-using-default-context spec: steps: - - name: step-00 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: pod-add-labels - name: step-01 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-using-default-context/policy-assert.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-using-default-context/policy-assert.yaml deleted file mode 100644 index b0bac17455..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-using-default-context/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: pod-add-labels -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-with-404-api-call/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-with-404-api-call/chainsaw-test.yaml index ba6957ba4c..f44b1cd908 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-with-404-api-call/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-with-404-api-call/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: mutate-with-404-api-call spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: mutate-404-api-call - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-with-404-api-call/policy-assert.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-with-404-api-call/policy-assert.yaml deleted file mode 100644 index 3a5cb6bb42..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/mutate-with-404-api-call/policy-assert.yaml +++ /dev/null @@ -1,4 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: mutate-404-api-call diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/trigger-name-exceeds-63-characters/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/trigger-name-exceeds-63-characters/chainsaw-test.yaml index 2d284859db..a2124eb241 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/trigger-name-exceeds-63-characters/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/trigger-name-exceeds-63-characters/chainsaw-test.yaml @@ -16,12 +16,20 @@ spec: file: configmap.yaml - assert: file: configmap-assert.yaml - - name: step-03 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: trigger-deployment-restarts - name: step-04 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/trigger-name-exceeds-63-characters/policy-assert.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/trigger-name-exceeds-63-characters/policy-assert.yaml deleted file mode 100755 index ee2b088ca8..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/trigger-name-exceeds-63-characters/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: trigger-deployment-restarts -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing-deprecated/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing-deprecated/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index e8ffe05a08..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing-deprecated/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: reload -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing-deprecated/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing-deprecated/chainsaw-test.yaml index bed00c2c4b..d3194b292a 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing-deprecated/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing-deprecated/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: variables-mutate-existing spec: steps: - - name: step-01 - try: - - apply: - file: chainsaw-step-01-apply-1-1.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: reload - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing-deprecated/chainsaw-step-01-apply-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing-deprecated/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing-deprecated/chainsaw-step-01-apply-1-1.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing-deprecated/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index e8ffe05a08..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: reload -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing/chainsaw-test.yaml index bed00c2c4b..d3194b292a 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: variables-mutate-existing spec: steps: - - name: step-01 - try: - - apply: - file: chainsaw-step-01-apply-1-1.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: reload - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing/chainsaw-step-01-apply-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing/chainsaw-step-01-apply-1-1.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/cornercases/variables-mutate-existing/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/basic-check-output/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/basic-check-output/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 7e9f14965b..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/basic-check-output/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: add-labels -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/basic-check-output/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/basic-check-output/chainsaw-test.yaml index 6c8d4ee540..8ea6583691 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/basic-check-output/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/basic-check-output/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: basic-check-output spec: steps: - - name: step-01 - try: - - apply: - file: chainsaw-step-01-apply-1-1.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: add-labels - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/basic-check-output/chainsaw-step-01-apply-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/basic-check-output/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/basic-check-output/chainsaw-step-01-apply-1-1.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/basic-check-output/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false(deprecated)/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false(deprecated)/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 46908e1174..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false(deprecated)/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: add-privileged-existing-namespaces -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false(deprecated)/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false(deprecated)/chainsaw-test.yaml index c4d5b022a0..8ab9947e17 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false(deprecated)/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false(deprecated)/chainsaw-test.yaml @@ -8,10 +8,20 @@ spec: try: - apply: file: chainsaw-step-01-apply-1-1.yaml - - apply: - file: chainsaw-step-01-apply-1-2.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: add-privileged-existing-namespaces - name: step-03 try: - assert: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false(deprecated)/chainsaw-step-01-apply-1-2.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false(deprecated)/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false(deprecated)/chainsaw-step-01-apply-1-2.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false(deprecated)/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 46908e1174..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: add-privileged-existing-namespaces -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false/chainsaw-test.yaml index c4d5b022a0..8ab9947e17 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false/chainsaw-test.yaml @@ -8,10 +8,20 @@ spec: try: - apply: file: chainsaw-step-01-apply-1-1.yaml - - apply: - file: chainsaw-step-01-apply-1-2.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: add-privileged-existing-namespaces - name: step-03 try: - assert: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false/chainsaw-step-01-apply-1-2.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false/chainsaw-step-01-apply-1-2.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/background-false/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create(deprecated)/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create(deprecated)/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 450edc769b..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create(deprecated)/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: mutate-existing-secret -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create(deprecated)/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create(deprecated)/chainsaw-test.yaml index 80b571cf07..528f9c25f3 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create(deprecated)/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create(deprecated)/chainsaw-test.yaml @@ -10,10 +10,20 @@ spec: file: chainsaw-step-01-apply-1-1.yaml - apply: file: chainsaw-step-01-apply-1-2.yaml - - apply: - file: chainsaw-step-01-apply-1-3.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: mutate-existing-secret - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create(deprecated)/chainsaw-step-01-apply-1-3.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create(deprecated)/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create(deprecated)/chainsaw-step-01-apply-1-3.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create(deprecated)/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902(deprecated)/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902(deprecated)/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 408b0e16e6..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902(deprecated)/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: test-post-mutation -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902(deprecated)/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902(deprecated)/chainsaw-test.yaml index 5abbcdd84d..dfba8b0de9 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902(deprecated)/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902(deprecated)/chainsaw-test.yaml @@ -10,10 +10,20 @@ spec: file: chainsaw-step-01-apply-1-1.yaml - apply: file: chainsaw-step-01-apply-1-2.yaml - - apply: - file: chainsaw-step-01-apply-1-3.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: test-post-mutation - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902(deprecated)/chainsaw-step-01-apply-1-3.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902(deprecated)/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902(deprecated)/chainsaw-step-01-apply-1-3.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902(deprecated)/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 408b0e16e6..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: test-post-mutation -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902/chainsaw-test.yaml index 5abbcdd84d..dfba8b0de9 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902/chainsaw-test.yaml @@ -10,10 +10,20 @@ spec: file: chainsaw-step-01-apply-1-1.yaml - apply: file: chainsaw-step-01-apply-1-2.yaml - - apply: - file: chainsaw-step-01-apply-1-3.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: test-post-mutation - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902/chainsaw-step-01-apply-1-3.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902/chainsaw-step-01-apply-1-3.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create-patchesJson6902/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 450edc769b..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: mutate-existing-secret -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create/chainsaw-test.yaml index 80b571cf07..528f9c25f3 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create/chainsaw-test.yaml @@ -10,10 +10,20 @@ spec: file: chainsaw-step-01-apply-1-1.yaml - apply: file: chainsaw-step-01-apply-1-2.yaml - - apply: - file: chainsaw-step-01-apply-1-3.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: mutate-existing-secret - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create/chainsaw-step-01-apply-1-3.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create/chainsaw-step-01-apply-1-3.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-create/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete(deprecated)/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete(deprecated)/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 0ac1ea7dcc..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete(deprecated)/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: test-post-mutation-delete-trigger -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete(deprecated)/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete(deprecated)/chainsaw-test.yaml index f1b3c78fee..cbb6e358ca 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete(deprecated)/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete(deprecated)/chainsaw-test.yaml @@ -12,10 +12,20 @@ spec: file: chainsaw-step-01-apply-1-2.yaml - apply: file: chainsaw-step-01-apply-1-3.yaml - - apply: - file: chainsaw-step-01-apply-1-4.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: test-post-mutation-delete-trigger - name: step-02 try: - delete: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete(deprecated)/chainsaw-step-01-apply-1-4.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete(deprecated)/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete(deprecated)/chainsaw-step-01-apply-1-4.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete(deprecated)/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 0ac1ea7dcc..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: test-post-mutation-delete-trigger -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete/chainsaw-test.yaml index f1b3c78fee..cbb6e358ca 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete/chainsaw-test.yaml @@ -12,10 +12,20 @@ spec: file: chainsaw-step-01-apply-1-2.yaml - apply: file: chainsaw-step-01-apply-1-3.yaml - - apply: - file: chainsaw-step-01-apply-1-4.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: test-post-mutation-delete-trigger - name: step-02 try: - delete: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete/chainsaw-step-01-apply-1-4.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete/chainsaw-step-01-apply-1-4.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-delete/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update(deprecated)/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update(deprecated)/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 450edc769b..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update(deprecated)/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: mutate-existing-secret -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update(deprecated)/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update(deprecated)/chainsaw-test.yaml index 003fe0ec41..c86909b3ff 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update(deprecated)/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update(deprecated)/chainsaw-test.yaml @@ -12,10 +12,20 @@ spec: file: chainsaw-step-01-apply-1-2.yaml - apply: file: chainsaw-step-01-apply-1-3.yaml - - apply: - file: chainsaw-step-01-apply-1-4.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: mutate-existing-secret - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update(deprecated)/chainsaw-step-01-apply-1-4.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update(deprecated)/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update(deprecated)/chainsaw-step-01-apply-1-4.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update(deprecated)/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 450edc769b..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: mutate-existing-secret -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update/chainsaw-test.yaml index 003fe0ec41..c86909b3ff 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update/chainsaw-test.yaml @@ -12,10 +12,20 @@ spec: file: chainsaw-step-01-apply-1-2.yaml - apply: file: chainsaw-step-01-apply-1-3.yaml - - apply: - file: chainsaw-step-01-apply-1-4.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: mutate-existing-secret - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update/chainsaw-step-01-apply-1-4.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update/chainsaw-step-01-apply-1-4.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/basic-update/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace(deprecated)/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace(deprecated)/chainsaw-test.yaml index 4fcc69c8fc..f1795a9c9d 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace(deprecated)/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace(deprecated)/chainsaw-test.yaml @@ -12,12 +12,20 @@ spec: try: - apply: file: secret.yaml - - name: step-03 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: mutate-existing-secret - name: step-04 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace(deprecated)/policy-ready.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace(deprecated)/policy-ready.yaml deleted file mode 100644 index 450edc769b..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace(deprecated)/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: mutate-existing-secret -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace/chainsaw-test.yaml index 4fcc69c8fc..f1795a9c9d 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace/chainsaw-test.yaml @@ -12,12 +12,20 @@ spec: try: - apply: file: secret.yaml - - name: step-03 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: mutate-existing-secret - name: step-04 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace/policy-ready.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace/policy-ready.yaml deleted file mode 100644 index 450edc769b..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/delete-trigger-namespace/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: mutate-existing-secret -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/descending-patchJson6902/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/descending-patchJson6902/chainsaw-test.yaml index 07a4b67638..48e581562d 100644 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/descending-patchJson6902/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/descending-patchJson6902/chainsaw-test.yaml @@ -4,14 +4,20 @@ metadata: name: descending-patchjson spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - name: step-01-assert - try: - - assert: - file: policy-assert.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: descending-jsonpatch - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/descending-patchJson6902/policy-assert.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/descending-patchJson6902/policy-assert.yaml deleted file mode 100644 index 641230b0fc..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/descending-patchJson6902/policy-assert.yaml +++ /dev/null @@ -1,5 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: descending-jsonpatch - diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude(deprecated)/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude(deprecated)/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 4f66697c6b..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude(deprecated)/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: cpol-multiple-rules-match-exclude -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude(deprecated)/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude(deprecated)/chainsaw-test.yaml index 016493eda4..429a76af22 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude(deprecated)/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude(deprecated)/chainsaw-test.yaml @@ -14,10 +14,20 @@ spec: file: chainsaw-step-01-apply-1-3.yaml - apply: file: chainsaw-step-01-apply-1-4.yaml - - apply: - file: chainsaw-step-01-apply-1-5.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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-multiple-rules-match-exclude - name: step-02 try: - command: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude(deprecated)/chainsaw-step-01-apply-1-5.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude(deprecated)/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude(deprecated)/chainsaw-step-01-apply-1-5.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude(deprecated)/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 4f66697c6b..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: cpol-multiple-rules-match-exclude -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude/chainsaw-test.yaml index 016493eda4..429a76af22 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude/chainsaw-test.yaml @@ -14,10 +14,20 @@ spec: file: chainsaw-step-01-apply-1-3.yaml - apply: file: chainsaw-step-01-apply-1-4.yaml - - apply: - file: chainsaw-step-01-apply-1-5.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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-multiple-rules-match-exclude - name: step-02 try: - command: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude/chainsaw-step-01-apply-1-5.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude/chainsaw-step-01-apply-1-5.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-rules-match-exclude/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources(deprecated)/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources(deprecated)/chainsaw-test.yaml index 88b230de6a..a5b8f2e2b1 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources(deprecated)/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources(deprecated)/chainsaw-test.yaml @@ -16,12 +16,20 @@ spec: try: - apply: file: pod.yaml - - name: step-04 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: org-label-inheritance-existing-1 - name: step-05 try: - assert: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources(deprecated)/policy-ready.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources(deprecated)/policy-ready.yaml deleted file mode 100644 index 931cfa7a33..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources(deprecated)/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: org-label-inheritance-existing-1 -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources/chainsaw-test.yaml index 88b230de6a..a5b8f2e2b1 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources/chainsaw-test.yaml @@ -16,12 +16,20 @@ spec: try: - apply: file: pod.yaml - - name: step-04 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: org-label-inheritance-existing-1 - name: step-05 try: - assert: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources/policy-ready.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources/policy-ready.yaml deleted file mode 100644 index 931cfa7a33..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/multiple-trigger-resources/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: org-label-inheritance-existing-1 -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-existing-node-status/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-existing-node-status/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 48e2262e17..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-existing-node-status/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: advertise-resource -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-existing-node-status/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-existing-node-status/chainsaw-test.yaml index 54f600e17c..3e5cdb11b3 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-existing-node-status/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-existing-node-status/chainsaw-test.yaml @@ -4,14 +4,23 @@ metadata: name: mutate-existing-node-status spec: steps: - - name: step-01 - try: - - apply: - file: chainsaw-step-01-apply-1-1.yaml + - name: create policy + use: + template: ../../../../../_step-templates/create-policy.yaml + with: + bindings: + - name: file + value: policy.yaml + - try: - apply: file: chainsaw-step-01-apply-1-2.yaml - - assert: - file: chainsaw-step-01-assert-1-1.yaml + - name: wait policy ready + use: + template: ../../../../../_step-templates/cluster-policy-ready.yaml + with: + bindings: + - name: name + value: advertise-resource - name: step-02 try: - script: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-existing-node-status/chainsaw-step-01-apply-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-existing-node-status/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-existing-node-status/chainsaw-step-01-apply-1-1.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-existing-node-status/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-pod-on-binding-request/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-pod-on-binding-request/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index ff992ad5ad..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-pod-on-binding-request/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: mutate-pod-on-binding-request -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-pod-on-binding-request/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-pod-on-binding-request/chainsaw-test.yaml index ab7fab981a..00ee7d9af9 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-pod-on-binding-request/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-pod-on-binding-request/chainsaw-test.yaml @@ -8,12 +8,24 @@ spec: try: - apply: file: chainsaw-step-01-apply-1-1.yaml - - apply: - file: chainsaw-step-01-apply-1-2.yaml + - name: create policy + use: + template: ../../../../../_step-templates/create-policy.yaml + with: + bindings: + - name: file + value: policy.yaml + - try: - apply: file: chainsaw-step-01-apply-1-3.yaml - - assert: - file: chainsaw-step-01-assert-1-1.yaml + - name: wait policy ready + use: + template: ../../../../../_step-templates/cluster-policy-ready.yaml + with: + bindings: + - name: name + value: mutate-pod-on-binding-request + - try: - assert: file: chainsaw-step-01-assert-1-2.yaml - name: step-02 diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-pod-on-binding-request/chainsaw-step-01-apply-1-2.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-pod-on-binding-request/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-pod-on-binding-request/chainsaw-step-01-apply-1-2.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/mutate-pod-on-binding-request/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector(deprecated)/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector(deprecated)/chainsaw-test.yaml index ed2b92f0f8..ea2cbf1ead 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector(deprecated)/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector(deprecated)/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: namespaceselector spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: org-label-inheritance-existing-standard - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector(deprecated)/policy-assert.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector(deprecated)/policy-assert.yaml deleted file mode 100644 index c399e38816..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector(deprecated)/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: org-label-inheritance-existing-standard -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector/chainsaw-test.yaml index ed2b92f0f8..ea2cbf1ead 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: namespaceselector spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: org-label-inheritance-existing-standard - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector/policy-assert.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector/policy-assert.yaml deleted file mode 100644 index c399e38816..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/namespaceselector/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: org-label-inheritance-existing-standard -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy(deprecated)/chainsaw-step-02-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy(deprecated)/chainsaw-step-02-assert-1-1.yaml deleted file mode 100755 index b70ab41388..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy(deprecated)/chainsaw-step-02-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: test-post-mutation-create-policy -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy(deprecated)/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy(deprecated)/chainsaw-test.yaml index ec03fed8d1..2f6c298b31 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy(deprecated)/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy(deprecated)/chainsaw-test.yaml @@ -12,12 +12,20 @@ spec: file: chainsaw-step-01-apply-1-2.yaml - apply: file: chainsaw-step-01-apply-1-3.yaml - - name: step-02 - try: - - apply: - file: chainsaw-step-02-apply-1-1.yaml - - assert: - file: chainsaw-step-02-assert-1-1.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: test-post-mutation-create-policy - name: step-03 try: - assert: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy(deprecated)/chainsaw-step-02-apply-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy(deprecated)/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy(deprecated)/chainsaw-step-02-apply-1-1.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy(deprecated)/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy/chainsaw-step-02-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy/chainsaw-step-02-assert-1-1.yaml deleted file mode 100755 index b70ab41388..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy/chainsaw-step-02-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: test-post-mutation-create-policy -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy/chainsaw-test.yaml index ec03fed8d1..2f6c298b31 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy/chainsaw-test.yaml @@ -12,12 +12,20 @@ spec: file: chainsaw-step-01-apply-1-2.yaml - apply: file: chainsaw-step-01-apply-1-3.yaml - - name: step-02 - try: - - apply: - file: chainsaw-step-02-apply-1-1.yaml - - assert: - file: chainsaw-step-02-assert-1-1.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: test-post-mutation-create-policy - name: step-03 try: - assert: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy/chainsaw-step-02-apply-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy/chainsaw-step-02-apply-1-1.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/basic-create-policy/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-configurations-for-mutate-existing/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-configurations-for-mutate-existing/chainsaw-test.yaml index b42d3b26ff..f33428f4a6 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-configurations-for-mutate-existing/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-configurations-for-mutate-existing/chainsaw-test.yaml @@ -12,12 +12,20 @@ spec: file: configmaps.yaml - apply: file: secrets.yaml - - name: step-02 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: test-post-mutation-create-policy - name: step-03 try: - assert: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-configurations-for-mutate-existing/policy-ready.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-configurations-for-mutate-existing/policy-ready.yaml deleted file mode 100755 index b70ab41388..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-configurations-for-mutate-existing/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: test-post-mutation-create-policy -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-mutate-existing-values/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-mutate-existing-values/chainsaw-test.yaml index ada0e95080..2060d0c920 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-mutate-existing-values/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-mutate-existing-values/chainsaw-test.yaml @@ -12,12 +12,20 @@ spec: file: configmaps.yaml - apply: file: secrets.yaml - - name: step-02 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: test-post-mutation-create-policy - name: step-03 try: - assert: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-mutate-existing-values/policy-ready.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-mutate-existing-values/policy-ready.yaml deleted file mode 100755 index b70ab41388..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/different-mutate-existing-values/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: test-post-mutation-create-policy -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector(deprecated)/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector(deprecated)/chainsaw-test.yaml index e20a1d3dbc..fa0d83a170 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector(deprecated)/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector(deprecated)/chainsaw-test.yaml @@ -18,12 +18,20 @@ spec: file: chainsaw-step-01-assert-1-2.yaml - assert: file: chainsaw-step-01-assert-1-3.yaml - - name: step-02 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: org-label-inheritance-existing - name: step-04 try: - assert: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector(deprecated)/policy-assert.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector(deprecated)/policy-assert.yaml deleted file mode 100644 index 11ec9368ec..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector(deprecated)/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: org-label-inheritance-existing -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector/chainsaw-test.yaml index e20a1d3dbc..fa0d83a170 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector/chainsaw-test.yaml @@ -18,12 +18,20 @@ spec: file: chainsaw-step-01-assert-1-2.yaml - assert: file: chainsaw-step-01-assert-1-3.yaml - - name: step-02 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: org-label-inheritance-existing - name: step-04 try: - assert: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector/policy-assert.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector/policy-assert.yaml deleted file mode 100644 index 11ec9368ec..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/onpolicyupdate/namespaceselector/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: org-label-inheritance-existing -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions(deprecated)/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions(deprecated)/chainsaw-test.yaml index 21e4b52151..6afda333bf 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions(deprecated)/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions(deprecated)/chainsaw-test.yaml @@ -8,12 +8,20 @@ spec: try: - apply: file: resources.yaml - - name: step-02 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: test - name: step-03 try: - assert: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions(deprecated)/policy-ready.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions(deprecated)/policy-ready.yaml deleted file mode 100644 index 73a5d1395d..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions(deprecated)/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: test -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions/chainsaw-test.yaml index 21e4b52151..6afda333bf 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions/chainsaw-test.yaml @@ -8,12 +8,20 @@ spec: try: - apply: file: resources.yaml - - name: step-02 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: test - name: step-03 try: - assert: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions/policy-ready.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions/policy-ready.yaml deleted file mode 100644 index 73a5d1395d..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/preconditions/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: test -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-context/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-context/chainsaw-test.yaml index 2ceac2da0f..81562853af 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-context/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-context/chainsaw-test.yaml @@ -8,12 +8,20 @@ spec: try: - apply: file: resources.yaml - - name: step-02 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: update-targets - name: step-03 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-context/policy-assert.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-context/policy-assert.yaml deleted file mode 100644 index 36e4e29d43..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-context/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: update-targets -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-preconditions/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-preconditions/chainsaw-test.yaml index 15e0e4878f..08bf7b88a6 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-preconditions/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-preconditions/chainsaw-test.yaml @@ -8,12 +8,20 @@ spec: try: - apply: file: resources.yaml - - name: step-02 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: update-targets - name: step-03 try: - apply: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-preconditions/policy-assert.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-preconditions/policy-assert.yaml deleted file mode 100644 index 36e4e29d43..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/target-preconditions/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: update-targets -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check(deprecated)/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check(deprecated)/chainsaw-test.yaml index b16acba7b4..425a0a0f3c 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check(deprecated)/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check(deprecated)/chainsaw-test.yaml @@ -15,9 +15,17 @@ spec: try: - apply: file: chainsaw-step-02-apply-1-1.yaml - - name: step-03 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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-mutate-existing-auth-check diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check(deprecated)/policy-assert.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check(deprecated)/policy-assert.yaml deleted file mode 100644 index c66662295b..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check(deprecated)/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: cpol-mutate-existing-auth-check -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check/chainsaw-test.yaml index b16acba7b4..425a0a0f3c 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check/chainsaw-test.yaml @@ -15,9 +15,17 @@ spec: try: - apply: file: chainsaw-step-02-apply-1-1.yaml - - name: step-03 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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-mutate-existing-auth-check diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check/policy-assert.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check/policy-assert.yaml deleted file mode 100644 index c66662295b..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/existing/validation/auth-check/cpol-standard-auth-check/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: cpol-mutate-existing-auth-check -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/mutate-node-status/chainsaw-step-01-assert-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/mutate-node-status/chainsaw-step-01-assert-1-1.yaml deleted file mode 100755 index 48e2262e17..0000000000 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/mutate-node-status/chainsaw-step-01-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: advertise-resource -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/mutate-node-status/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/mutate-node-status/chainsaw-test.yaml index cf1627ab88..674f80f4d6 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/mutate-node-status/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/mutate-node-status/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: mutate-node-status spec: steps: - - name: step-01 - try: - - apply: - file: chainsaw-step-01-apply-1-1.yaml - - assert: - file: chainsaw-step-01-assert-1-1.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: advertise-resource - name: step-02 try: - script: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/mutate-node-status/chainsaw-step-01-apply-1-1.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/mutate-node-status/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/mutate-node-status/chainsaw-step-01-apply-1-1.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/mutate-node-status/policy.yaml diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/userInfo-roles-clusterRoles/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/userInfo-roles-clusterRoles/chainsaw-test.yaml index d28ff6dd10..a595c32993 100755 --- a/test/conformance/chainsaw/mutate/clusterpolicy/standard/userInfo-roles-clusterRoles/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/clusterpolicy/standard/userInfo-roles-clusterRoles/chainsaw-test.yaml @@ -16,8 +16,20 @@ spec: file: chainsaw-step-01-apply-1-4.yaml - apply: file: chainsaw-step-01-apply-1-5.yaml - - apply: - file: chainsaw-step-01-apply-1-6.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: record-creation-details - name: step-02 try: - script: diff --git a/test/conformance/chainsaw/mutate/clusterpolicy/standard/userInfo-roles-clusterRoles/chainsaw-step-01-apply-1-6.yaml b/test/conformance/chainsaw/mutate/clusterpolicy/standard/userInfo-roles-clusterRoles/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/clusterpolicy/standard/userInfo-roles-clusterRoles/chainsaw-step-01-apply-1-6.yaml rename to test/conformance/chainsaw/mutate/clusterpolicy/standard/userInfo-roles-clusterRoles/policy.yaml diff --git a/test/conformance/chainsaw/mutate/e2e/emit-warning/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/e2e/emit-warning/chainsaw-test.yaml index 6ddc4058da..064747daae 100644 --- a/test/conformance/chainsaw/mutate/e2e/emit-warning/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/e2e/emit-warning/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: test-emit-warning spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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: add-labels - name: step-02 try: - script: diff --git a/test/conformance/chainsaw/mutate/e2e/emit-warning/policy-assert.yaml b/test/conformance/chainsaw/mutate/e2e/emit-warning/policy-assert.yaml deleted file mode 100644 index 6703bfb6a1..0000000000 --- a/test/conformance/chainsaw/mutate/e2e/emit-warning/policy-assert.yaml +++ /dev/null @@ -1,4 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: add-labels diff --git a/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-context/chainsaw-step-02-assert-1-1.yaml b/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-context/chainsaw-step-02-assert-1-1.yaml deleted file mode 100755 index f8af584a54..0000000000 --- a/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-context/chainsaw-step-02-assert-1-1.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: foreach-patchstrategicmerge-context-policy -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-context/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-context/chainsaw-test.yaml index 92b15af4aa..7219c4fc0f 100755 --- a/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-context/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-context/chainsaw-test.yaml @@ -10,12 +10,20 @@ spec: file: chainsaw-step-01-apply-1-1.yaml - apply: file: chainsaw-step-01-apply-1-2.yaml - - name: step-02 - try: - - apply: - file: chainsaw-step-02-apply-1-1.yaml - - assert: - file: chainsaw-step-02-assert-1-1.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: foreach-patchstrategicmerge-context-policy - name: step-03 try: - apply: diff --git a/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-context/chainsaw-step-02-apply-1-1.yaml b/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-context/policy.yaml similarity index 100% rename from test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-context/chainsaw-step-02-apply-1-1.yaml rename to test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-context/policy.yaml diff --git a/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-preconditions/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-preconditions/chainsaw-test.yaml index dec81b1d63..eb03fbc8ab 100755 --- a/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-preconditions/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-preconditions/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: foreach-patchstrategicmerge-preconditions spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: replace-docker-hub - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-preconditions/policy-ready.yaml b/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-preconditions/policy-ready.yaml deleted file mode 100644 index ad1a1e1f5a..0000000000 --- a/test/conformance/chainsaw/mutate/e2e/foreach-patchStrategicMerge-preconditions/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: replace-docker-hub -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/e2e/jmespath-logic/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/e2e/jmespath-logic/chainsaw-test.yaml index cc3875b5d2..48c599280e 100755 --- a/test/conformance/chainsaw/mutate/e2e/jmespath-logic/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/e2e/jmespath-logic/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: jmespath-logic spec: steps: - - name: step-01 - try: - - apply: - file: manifests.yaml - - assert: - file: policy-one-ready.yaml + - name: create policy + use: + template: ../../../_step-templates/create-policy.yaml + with: + bindings: + - name: file + value: manifests.yaml + - name: wait policy ready + use: + template: ../../../_step-templates/cluster-policy-ready.yaml + with: + bindings: + - name: name + value: mutate-policy - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/e2e/jmespath-logic/policy-one-ready.yaml b/test/conformance/chainsaw/mutate/e2e/jmespath-logic/policy-one-ready.yaml deleted file mode 100644 index d2e0f36f4a..0000000000 --- a/test/conformance/chainsaw/mutate/e2e/jmespath-logic/policy-one-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: mutate-policy -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global-addifnotpresent/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global-addifnotpresent/chainsaw-test.yaml index 0f46e98847..a426f68d65 100755 --- a/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global-addifnotpresent/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global-addifnotpresent/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: patchstrategicmerge-global-addifnotpresent spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: add-safe-to-evict - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global-addifnotpresent/policy-ready.yaml b/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global-addifnotpresent/policy-ready.yaml deleted file mode 100644 index 480c95f0fc..0000000000 --- a/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global-addifnotpresent/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: add-safe-to-evict -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global/chainsaw-test.yaml index 7a61638046..0e46812024 100755 --- a/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: patchstrategicmerge-global spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: set-image-pull-secret - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global/policy-ready.yaml b/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global/policy-ready.yaml deleted file mode 100644 index ec9f47c302..0000000000 --- a/test/conformance/chainsaw/mutate/e2e/patchStrategicMerge-global/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: set-image-pull-secret -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/e2e/patchesJson6902-replace/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/e2e/patchesJson6902-replace/chainsaw-test.yaml index a685d6adc0..836c174885 100755 --- a/test/conformance/chainsaw/mutate/e2e/patchesJson6902-replace/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/e2e/patchesJson6902-replace/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: patchesjson6902-replace spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: mutate-ingress-host - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/e2e/patchesJson6902-replace/policy-ready.yaml b/test/conformance/chainsaw/mutate/e2e/patchesJson6902-replace/policy-ready.yaml deleted file mode 100644 index ba7571c941..0000000000 --- a/test/conformance/chainsaw/mutate/e2e/patchesJson6902-replace/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: mutate-ingress-host -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/e2e/patchesjson6902-simple/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/e2e/patchesjson6902-simple/chainsaw-test.yaml index 689fffd904..1c34df61b6 100755 --- a/test/conformance/chainsaw/mutate/e2e/patchesjson6902-simple/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/e2e/patchesjson6902-simple/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: patchesjson6902-simple spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: add-image-as-env-var - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/e2e/patchesjson6902-simple/policy-ready.yaml b/test/conformance/chainsaw/mutate/e2e/patchesjson6902-simple/policy-ready.yaml deleted file mode 100644 index da767ab21e..0000000000 --- a/test/conformance/chainsaw/mutate/e2e/patchesjson6902-simple/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: add-image-as-env-var -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/e2e/simple-conditional/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/e2e/simple-conditional/chainsaw-test.yaml index c963f1a4e7..67f400e2f4 100755 --- a/test/conformance/chainsaw/mutate/e2e/simple-conditional/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/e2e/simple-conditional/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: simple-conditional spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: set-runasnonroot-true - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/e2e/simple-conditional/policy-ready.yaml b/test/conformance/chainsaw/mutate/e2e/simple-conditional/policy-ready.yaml deleted file mode 100644 index 11667b7057..0000000000 --- a/test/conformance/chainsaw/mutate/e2e/simple-conditional/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: set-runasnonroot-true -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/e2e/variables-in-keys/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/e2e/variables-in-keys/chainsaw-test.yaml index be3c4131b6..c80be98477 100755 --- a/test/conformance/chainsaw/mutate/e2e/variables-in-keys/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/e2e/variables-in-keys/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: variables-in-keys spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: structured-logs-sidecar - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/e2e/variables-in-keys/policy-ready.yaml b/test/conformance/chainsaw/mutate/e2e/variables-in-keys/policy-ready.yaml deleted file mode 100644 index 5395eb4672..0000000000 --- a/test/conformance/chainsaw/mutate/e2e/variables-in-keys/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: structured-logs-sidecar -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/policy/cornercases/foreach-remove-elements/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/policy/cornercases/foreach-remove-elements/chainsaw-test.yaml index 2d23d5178e..8db23bab97 100755 --- a/test/conformance/chainsaw/mutate/policy/cornercases/foreach-remove-elements/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/policy/cornercases/foreach-remove-elements/chainsaw-test.yaml @@ -4,15 +4,23 @@ metadata: name: foreach-remove-elements spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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/policy-ready.yaml + with: + bindings: + - name: name + value: foreach-remove-elements - name: step-02 try: - apply: file: pod.yaml - assert: - file: pod-assert.yaml + file: pod-assert.yaml \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/policy/cornercases/foreach-remove-elements/policy-assert.yaml b/test/conformance/chainsaw/mutate/policy/cornercases/foreach-remove-elements/policy-assert.yaml deleted file mode 100644 index 368e9a1688..0000000000 --- a/test/conformance/chainsaw/mutate/policy/cornercases/foreach-remove-elements/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: Policy -metadata: - name: foreach-remove-elements -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/policy/standard/existing/validation/auth-check/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/policy/standard/existing/validation/auth-check/chainsaw-test.yaml index 51d63dd0af..aa877c9e98 100755 --- a/test/conformance/chainsaw/mutate/policy/standard/existing/validation/auth-check/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/policy/standard/existing/validation/auth-check/chainsaw-test.yaml @@ -19,9 +19,19 @@ spec: try: - apply: file: chainsaw-step-03-apply-1-1.yaml - - name: step-04 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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/policy-ready.yaml + with: + bindings: + - name: name + value: pol-mutate-existing-auth-check + - name: namespace + value: pol-mutate-existing-auth-check-ns diff --git a/test/conformance/chainsaw/mutate/policy/standard/existing/validation/auth-check/policy-assert.yaml b/test/conformance/chainsaw/mutate/policy/standard/existing/validation/auth-check/policy-assert.yaml deleted file mode 100644 index 01c703dd57..0000000000 --- a/test/conformance/chainsaw/mutate/policy/standard/existing/validation/auth-check/policy-assert.yaml +++ /dev/null @@ -1,10 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: Policy -metadata: - name: pol-mutate-existing-auth-check - namespace: pol-mutate-existing-auth-check-ns -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/refactor/foreach/add-and-remove/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/refactor/foreach/add-and-remove/chainsaw-test.yaml index cb5d44824f..b6154aed02 100755 --- a/test/conformance/chainsaw/mutate/refactor/foreach/add-and-remove/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/refactor/foreach/add-and-remove/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: add-and-remove spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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/policy-ready.yaml + with: + bindings: + - name: name + value: foreach-remove-elements - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/refactor/foreach/add-and-remove/policy-assert.yaml b/test/conformance/chainsaw/mutate/refactor/foreach/add-and-remove/policy-assert.yaml deleted file mode 100644 index 368e9a1688..0000000000 --- a/test/conformance/chainsaw/mutate/refactor/foreach/add-and-remove/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: Policy -metadata: - name: foreach-remove-elements -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/refactor/foreach/remove-and-add/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/refactor/foreach/remove-and-add/chainsaw-test.yaml index b937fff422..403e6c1350 100755 --- a/test/conformance/chainsaw/mutate/refactor/foreach/remove-and-add/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/refactor/foreach/remove-and-add/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: remove-and-add spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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/policy-ready.yaml + with: + bindings: + - name: name + value: foreach-remove-elements - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/refactor/foreach/remove-and-add/policy-assert.yaml b/test/conformance/chainsaw/mutate/refactor/foreach/remove-and-add/policy-assert.yaml deleted file mode 100644 index 368e9a1688..0000000000 --- a/test/conformance/chainsaw/mutate/refactor/foreach/remove-and-add/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: Policy -metadata: - name: foreach-remove-elements -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-ascending-order/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-ascending-order/chainsaw-test.yaml index 8fbff779fb..e40f4b618a 100755 --- a/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-ascending-order/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-ascending-order/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: remove-multiple-elements-in-ascending-order spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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/policy-ready.yaml + with: + bindings: + - name: name + value: foreach-remove-elements - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-ascending-order/policy-assert.yaml b/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-ascending-order/policy-assert.yaml deleted file mode 100644 index 368e9a1688..0000000000 --- a/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-ascending-order/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: Policy -metadata: - name: foreach-remove-elements -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-descending-order/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-descending-order/chainsaw-test.yaml index 66b450c359..e577306262 100755 --- a/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-descending-order/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-descending-order/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: remove-multiple-elements-in-descending-order spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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/policy-ready.yaml + with: + bindings: + - name: name + value: foreach-remove-elements - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-descending-order/policy-assert.yaml b/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-descending-order/policy-assert.yaml deleted file mode 100644 index 368e9a1688..0000000000 --- a/test/conformance/chainsaw/mutate/refactor/foreach/remove-multiple-elements-in-descending-order/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: Policy -metadata: - name: foreach-remove-elements -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/refactor/k10-minimum-retention/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/refactor/k10-minimum-retention/chainsaw-test.yaml index 816a363222..a9b32fda87 100755 --- a/test/conformance/chainsaw/mutate/refactor/k10-minimum-retention/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/refactor/k10-minimum-retention/chainsaw-test.yaml @@ -10,12 +10,20 @@ spec: file: crd.yaml - assert: file: crd-assert.yaml - - name: step-02 - try: - - apply: - file: policy.yaml - - assert: - file: policy-ready.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: k10-minimum-retention - name: step-03 try: - apply: diff --git a/test/conformance/chainsaw/mutate/refactor/k10-minimum-retention/policy-ready.yaml b/test/conformance/chainsaw/mutate/refactor/k10-minimum-retention/policy-ready.yaml deleted file mode 100644 index 99fd5a77ed..0000000000 --- a/test/conformance/chainsaw/mutate/refactor/k10-minimum-retention/policy-ready.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: ClusterPolicy -metadata: - name: k10-minimum-retention -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready \ No newline at end of file diff --git a/test/conformance/chainsaw/mutate/refactor/nested-foreach/remove-all-env-vars/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/refactor/nested-foreach/remove-all-env-vars/chainsaw-test.yaml index cdf48895af..b5cb52df0d 100755 --- a/test/conformance/chainsaw/mutate/refactor/nested-foreach/remove-all-env-vars/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/refactor/nested-foreach/remove-all-env-vars/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: remove-all-env-vars spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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/policy-ready.yaml + with: + bindings: + - name: name + value: foreach-remove-elements - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/refactor/nested-foreach/remove-all-env-vars/policy-assert.yaml b/test/conformance/chainsaw/mutate/refactor/nested-foreach/remove-all-env-vars/policy-assert.yaml deleted file mode 100644 index 368e9a1688..0000000000 --- a/test/conformance/chainsaw/mutate/refactor/nested-foreach/remove-all-env-vars/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: Policy -metadata: - name: foreach-remove-elements -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-ascending-order/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-ascending-order/chainsaw-test.yaml index 8fbff779fb..e40f4b618a 100755 --- a/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-ascending-order/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-ascending-order/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: remove-multiple-elements-in-ascending-order spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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/policy-ready.yaml + with: + bindings: + - name: name + value: foreach-remove-elements - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-ascending-order/policy-assert.yaml b/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-ascending-order/policy-assert.yaml deleted file mode 100644 index 368e9a1688..0000000000 --- a/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-ascending-order/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: Policy -metadata: - name: foreach-remove-elements -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready diff --git a/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-descending-order/chainsaw-test.yaml b/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-descending-order/chainsaw-test.yaml index aa0834eb18..06693f4ac6 100755 --- a/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-descending-order/chainsaw-test.yaml +++ b/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-descending-order/chainsaw-test.yaml @@ -4,12 +4,20 @@ metadata: name: remove-multiple-elements-in-descending-order spec: steps: - - name: step-01 - try: - - apply: - file: policy.yaml - - assert: - file: policy-assert.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/policy-ready.yaml + with: + bindings: + - name: name + value: foreach-remove-elements - name: step-02 try: - apply: diff --git a/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-descending-order/policy-assert.yaml b/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-descending-order/policy-assert.yaml deleted file mode 100644 index 368e9a1688..0000000000 --- a/test/conformance/chainsaw/mutate/refactor/simple/remove-multiple-elements-in-descending-order/policy-assert.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: kyverno.io/v1 -kind: Policy -metadata: - name: foreach-remove-elements -status: - conditions: - - reason: Succeeded - status: "True" - type: Ready