Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Flakey test about lifecycle hooks. Fixes #10897 #10898

Merged
merged 10 commits into from
Apr 13, 2023
27 changes: 18 additions & 9 deletions test/e2e/hooks_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,8 @@ spec:
- name: argosay
container:
image: argoproj/argosay:v2
command: ["/argosay"]
command: ["/bin/sh", "-c"]
args: ["/bin/sleep 1; /argosay"]
`).When().
SubmitWorkflow().
WaitForWorkflow(fixtures.ToBeSucceeded).
Expand Down Expand Up @@ -88,12 +89,14 @@ spec:
- name: argosay
container:
image: argoproj/argosay:v2
command: ["/argosay", "sleep 5", "exit 1"]
command: ["/bin/sh", "-c"]
args: ["/bin/sleep 1; /argosay; exit 1"]

- name: hook
container:
image: argoproj/argosay:v2
command: ["/argosay"]
command: ["/bin/sh", "-c"]
args: ["/bin/sleep 1; /argosay"]
`).When().
SubmitWorkflow().
WaitForWorkflow(fixtures.ToBeFailed).
Expand Down Expand Up @@ -143,7 +146,8 @@ spec:
- name: argosay
container:
image: argoproj/argosay:v2
command: ["/argosay"]
command: ["/bin/sh", "-c"]
args: ["/bin/sleep 1; /argosay"]
`).When().
SubmitWorkflow().
WaitForWorkflow(fixtures.ToBeSucceeded).
Expand Down Expand Up @@ -192,11 +196,13 @@ spec:
- name: argosay
container:
image: argoproj/argosay:v2
command: ["/argosay", "sleep 5", "exit 1"]
command: ["/bin/sh", "-c"]
args: ["/bin/sleep 1; /argosay; exit 1"]
- name: hook
container:
image: argoproj/argosay:v2
command: ["/argosay"]
command: ["/bin/sh", "-c"]
args: ["/bin/sleep 1; /argosay"]
`).When().
SubmitWorkflow().
WaitForWorkflow(fixtures.ToBeFailed).
Expand Down Expand Up @@ -248,7 +254,8 @@ spec:
- name: argosay
container:
image: argoproj/argosay:v2
command: ["/argosay"]
command: ["/bin/sh", "-c"]
args: ["/bin/sleep 1; /argosay"]
`).When().
SubmitWorkflow().
WaitForWorkflow(fixtures.ToBeSucceeded).
Expand Down Expand Up @@ -298,11 +305,13 @@ spec:
- name: argosay
container:
image: argoproj/argosay:v2
command: ["/argosay", "sleep 5", "exit 1"]
command: ["/bin/sh", "-c"]
args: ["/bin/sleep 1; /argosay; exit 1"]
- name: hook
container:
image: argoproj/argosay:v2
command: ["/argosay"]
command: ["/bin/sh", "-c"]
args: ["/bin/sleep 1; /argosay"]
`).When().
SubmitWorkflow().
WaitForWorkflow(fixtures.ToBeFailed).
Expand Down