vis

a vi-like editor based on Plan 9's structural regular expressions

git clone https://9o.is/git/vis.git

commit 73986885e435dfaf2b31a853f57fb6e7b82b0eb3
parent 68b1db7b0d64fe30c7c99e8c1949b6f4048869f3
Author: Marc André Tanner <mat@brain-dump.org>
Date:   Wed, 28 Dec 2016 16:16:26 +0100

Make sure that info messages are printed before test case is run

Useful for hanging tests also redirect stdout to /dev/null for
better output on Travis.

Diffstat:
Mlua/test.sh | 5+++--
Msam/test.sh | 2+-
Mvis/test.sh | 5+++--
3 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/lua/test.sh b/lua/test.sh @@ -18,9 +18,10 @@ for t in $test_files; do TESTS_RUN=$((TESTS_RUN + 1)) t=${t%.in} t=${t#./} - $VIS "$t".in < /dev/null 2> /dev/null - printf "%-30s" "$t" + + $VIS "$t".in < /dev/null > /dev/null 2>&1 + if [ -e "$t".out ]; then if cmp -s "$t".ref "$t".out 2> /dev/null; then printf "PASS\n" diff --git a/sam/test.sh b/sam/test.sh @@ -73,7 +73,7 @@ for t in $TESTS; do printf "Running test %s with vis ... " "$t" - $VIS "+,{ $NL $CMD $NL wq! $VIS_OUT $NL }" "$IN" 2>/dev/null + $VIS "+,{ $NL $CMD $NL wq! $VIS_OUT $NL }" "$IN" >/dev/null 2>&1 if [ $? -ne 0 -o ! -e "$VIS_OUT" ]; then printf "ERROR\n" elif cmp -s "$REF" "$VIS_OUT"; then diff --git a/vis/test.sh b/vis/test.sh @@ -18,9 +18,10 @@ for t in $test_files; do TESTS_RUN=$((TESTS_RUN + 1)) t=${t%.in} t=${t#./} - $VIS "$t".in < /dev/null 2> /dev/null - printf "%-50s" "$t" + + $VIS "$t".in < /dev/null > /dev/null 2>&1 + if [ -e "$t".out ]; then if cmp -s "$t".ref "$t".out 2> /dev/null; then printf "PASS\n"