Skip to content

Commit

Permalink
Add changes
Browse files Browse the repository at this point in the history
Signed-off-by: FlamingSaint <[email protected]>
  • Loading branch information
FlamingSaint committed Jul 23, 2024
1 parent 8f0ee2b commit b17125a
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions scripts/spm-integration-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -89,19 +89,14 @@ validate_service_metrics() {
echo "Metric datapoints found for service '$service': " "${metric_points[@]}"
# Check that atleast some values are non-zero after the threshold
local non_zero_count=0
local expected_non_zero_count=5
local expected_non_zero_count=4
local zero_count=0
local expected_max_zero_count=4
local flag=false # Becomes true after first non-zero value
for value in "${metric_points[@]}"; do
if [[ $(echo "$value > 0.0" | bc) == "1" ]]; then
flag=true
non_zero_count=$((non_zero_count + 1))
else
if [ $flag == true ]; then
echo "❌ ERROR: Zero values appearing after a non-zero value not expected"
return 1
fi
zero_count=$((zero_count + 1))
fi

Expand Down

0 comments on commit b17125a

Please sign in to comment.