Skip to content

Commit 2904e0f

Browse files
committed
test harness: Fix the pretty-printer's padding implementation.
The new implementation is less efficient but definitely correct.
1 parent d5d2f22 commit 2904e0f

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

tests/test-highlighting.zsh

+1-3
Original file line numberDiff line numberDiff line change
@@ -227,9 +227,7 @@ run_test_internal() {
227227
left_column=( "expected_region_highlight" "${(qq)expected_region_highlight[@]}" )
228228
right_column=( "region_highlight" "${(qq)region_highlight[@]}" )
229229
integer difference=$(( $#right_column - $#left_column ))
230-
if (( difference > 0 )); then
231-
left_column+=( ${(r:2*difference::. :):-} )
232-
fi
230+
repeat $difference do left_column+=(.); done
233231
paste \
234232
=(print -rC1 -- $left_column) \
235233
=(print -rC1 -- $right_column) \

0 commit comments

Comments
 (0)