diff options
| author | Marc André Tanner <mat@brain-dump.org> | 2016-11-05 14:25:35 +0100 |
|---|---|---|
| committer | Marc André Tanner <mat@brain-dump.org> | 2016-11-05 14:25:35 +0100 |
| commit | b9ceda978bf9beaff19c69f59d1421103c490f7a (patch) | |
| tree | 35a8866aa0fe7e89f39709a3f2170b070b611ace | |
| parent | ef5ea09c8a7f608af7bff5574afae672e3f0adfb (diff) | |
| download | vis-b9ceda978bf9beaff19c69f59d1421103c490f7a.tar.gz vis-b9ceda978bf9beaff19c69f59d1421103c490f7a.tar.xz | |
test/sam: improve test output
Redirect the vis UI to /dev/null. Let it write to an output file
instead of redirecting stdout, keeps the terminal in a sane state.
| -rwxr-xr-x | sam/test.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sam/test.sh b/sam/test.sh index 99d48cd..42970b3 100755 --- a/sam/test.sh +++ b/sam/test.sh @@ -54,8 +54,8 @@ for t in $TESTS; do printf "Running test %s with vis ... " "$t" - cat "$IN" | $VIS "+{ $NL $CMD $NL wq! $NL }" - > "$VIS_OUT" - if [ $? -ne 0 ]; then + $VIS "+{ $NL $CMD $NL wq! $VIS_OUT $NL }" "$IN" 2>/dev/null + if [ $? -ne 0 -o ! -e "$VIS_OUT" ]; then printf "ERROR\n" elif cmp -s "$REF" "$VIS_OUT"; then printf "OK\n" |
