Skip to content

Commit

Permalink
test(e2e): fix catch syntx err
Browse files Browse the repository at this point in the history
  • Loading branch information
whg517 committed Dec 31, 2024
1 parent 6478bf6 commit 073e250
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 18 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ chainsaw-setup: ## Run the chainsaw setup
.PHONY: chainsaw-test
chainsaw-test: chainsaw ## Run the chainsaw test
- KUBECONFIG=$(KIND_KUBECONFIG) $(CHAINSAW) test --cluster cluster-1=$(KIND_KUBECONFIG) --test-dir ./test/e2e/tls
KUBECONFIG=$(KIND_KUBECONFIG) kubectl logs -n secret-operator-system -l "app.kubernetes.io/name=secret-operator"
KUBECONFIG=$(KIND_KUBECONFIG) kubectl logs --tail=-1 -n secret-operator-system -l "app.kubernetes.io/name=secret-operator"

.PHONY: chainsaw-cleanup
chainsaw-cleanup: ## Run the chainsaw cleanup
Expand Down
16 changes: 8 additions & 8 deletions test/e2e/krb5/chainsaw-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -89,14 +89,14 @@ spec:
file: node-scope.yaml
- assert:
file: node-scope-assert.yaml
- catch:
- script:
env:
- name: NAMESPACE
value: ($namespace)
content: |
kubectl -n "$NAMESPACE" get pod
kubectl -n "$NAMESPACE" describe pod
catch:
- script:
env:
- name: NAMESPACE
value: ($namespace)
content: |
kubectl -n "$NAMESPACE" get pod
kubectl -n "$NAMESPACE" describe pod
- try:
- apply:
file: service-scope.yaml
Expand Down
17 changes: 8 additions & 9 deletions test/e2e/tls/chainsaw-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,14 @@ spec:
file: tls-scope.yaml
- assert:
file: tls-scope-assert.yaml
- catch:
- script:
env:
- name: NAMESPACE
value: ($namespace)
content: |
kubectl -n "$NAMESPACE" get pod
kubectl -n "$NAMESPACE" describe pod
catch:
- script:
env:
- name: NAMESPACE
value: ($namespace)
content: |
kubectl -n "$NAMESPACE" get pod
kubectl -n "$NAMESPACE" describe pod
# tls will expires case
- try:
- apply:
Expand Down

0 comments on commit 073e250

Please sign in to comment.