fixed counter variables

This commit is contained in:
Daniel Sanche 2020-04-08 17:45:23 -07:00
parent ae89359798
commit fd739a066f

View file

@ -48,10 +48,10 @@ jobs:
REQUEST_COUNT="0" REQUEST_COUNT="0"
while [[ "$REQUEST_COUNT" -lt "50" ]]; do while [[ "$REQUEST_COUNT" -lt "50" ]]; do
sleep 5 sleep 5
REQUEST_COUNT=$(kubectl logs -l app=loadgenerator | grep Total | awk '{print $2}') REQUEST_COUNT=$(kubectl logs -l app=loadgenerator | grep Aggregated | awk '{print $2}')
done done
# ensure there are no errors hitting endpoints # ensure there are no errors hitting endpoints
ERROR_COUNT=$(kubectl logs -l app=loadgenerator | grep Total | awk '{print $3}' | sed "s/[(][^)]*[)]//g") ERROR_COUNT=$(kubectl logs -l app=loadgenerator | grep Aggregated | awk '{print $3}' | sed "s/[(][^)]*[)]//g")
if [[ "$ERROR_COUNT" -gt "0" ]]; then if [[ "$ERROR_COUNT" -gt "0" ]]; then
exit 1 exit 1
fi fi