File tree 1 file changed +18
-10
lines changed
test/openshift/e2e/parallel/1-057_validate_notifications
1 file changed +18
-10
lines changed Original file line number Diff line number Diff line change @@ -3,17 +3,25 @@ kind: TestStep
3
3
commands :
4
4
- script : |
5
5
set -e
6
- sleep 5
7
6
smtp4dev_pod=$(kubectl get pod -l=app=smtp4dev -o NAME -n $NAMESPACE)
8
- exit_code=$(kubectl -n $NAMESPACE exec --stdin "${smtp4dev_pod}" -- /bin/bash \
9
- -c 'if [[ $(grep -rnw /tmp -e "Subject: Application my-app-3 has been created.") ]]; then
10
- exit 0; else
11
- exit 1;
12
- fi')
13
7
8
+ while :
9
+ do
10
+ if [[ $timer -eq 120 ]]; then
11
+ echo "timed out while waiting for email notification"
12
+ exit 1
13
+ fi
14
+
15
+ exit_code=$(kubectl -n $NAMESPACE exec --stdin "${smtp4dev_pod}" -- /bin/bash \
16
+ -c 'if [[ $(grep -rnw /tmp -e "Subject: Application my-app-3 has been created.") ]]; then
17
+ exit 0; else
18
+ exit 1;
19
+ fi')
14
20
15
- if [[ $exit_code -eq 0 ]]; then
21
+ if [[ $exit_code -eq 0 ]]; then
16
22
exit 0
17
- else
18
- exit 1
19
- fi
23
+ fi
24
+
25
+ timer=$((timer+5))
26
+ sleep 5
27
+ done
You can’t perform that action at this time.
0 commit comments