Skip to content

Commit e287791

Browse files
authored
Fix arithmetic expression exit status in test-all.sh (#121) (#122)
Replace ((TESTED++)) with TESTED=$((TESTED + 1)) to avoid returning exit status 1 when TESTED is 0. The post-increment expression evaluates to 0, which bash treats as false, causing issues with set -e and incorrect exit status reporting in IDE terminals.
1 parent e7863fa commit e287791

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tests/deb/test-all.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ for target in "${BUILD_TARGETS[@]}"; do
107107

108108
if ./tests/deb/test-package.sh "$deb_file" "$image"; then
109109
echo "PASSED: $rid on $image"
110-
((TESTED++))
110+
TESTED=$((TESTED + 1))
111111
else
112112
echo "FAILED: $rid on $image"
113113
FAILED=1

0 commit comments

Comments
 (0)