File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -153,7 +153,7 @@ GET_ATTRS_SQS_CMD="awslocal sqs get-queue-attributes --queue-url ${queue_url} --
153
153
154
154
cordoned=0
155
155
tainted=0
156
- not_evicted =0
156
+ evicted =0
157
157
message_deleted=0
158
158
test_node=" ${TEST_NODE:- $CLUSTER_NAME -worker} "
159
159
for i in $( seq 1 $TAINT_CHECK_CYCLES ) ; do
@@ -167,9 +167,9 @@ for i in $(seq 1 $TAINT_CHECK_CYCLES); do
167
167
tainted=1
168
168
fi
169
169
170
- if [[ $cordoned -eq 1 && $( kubectl get deployments regular-pod-test -o=jsonpath=' {.status.unavailableReplicas}' ) -eq 0 ]]; then
171
- echo " ✅ Verified the regular-pod-test pod was NOT evicted!"
172
- not_evicted =1
170
+ if [[ $cordoned -eq 1 && $( kubectl get deployments regular-pod-test -o=jsonpath=' {.status.unavailableReplicas}' ) -eq 1 ]]; then
171
+ echo " ✅ Verified the regular-pod-test pod was evicted!"
172
+ evicted =1
173
173
fi
174
174
175
175
if [[ ${tainted} -eq 1 && $( kubectl exec -i " ${localstack_pod} " -- bash -c " ${GET_ATTRS_SQS_CMD} " | jq ' (.Attributes.ApproximateNumberOfMessagesNotVisible|tonumber) + (.Attributes.ApproximateNumberOfMessages|tonumber)' ) -eq 0 ]]; then
@@ -189,8 +189,8 @@ if [[ $cordoned -eq 0 ]]; then
189
189
elif [[ $tainted -eq 0 ]]; then
190
190
echo " ❌ Worker node was not tainted"
191
191
fail_and_exit 3
192
- elif [[ $not_evicted -eq 0 ]]; then
193
- echo " ❌ regular-pod-test was evicted"
192
+ elif [[ $evicted -eq 0 ]]; then
193
+ echo " ❌ regular-pod-test was NOT evicted"
194
194
fail_and_exit 3
195
195
elif [[ $message_deleted -eq 0 ]]; then
196
196
echo " ❌ message was not removed from the queue after processing"
You can’t perform that action at this time.
0 commit comments