aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2024-09-03 15:14:08 -0400
committerBruce Hill <bruce@bruce-hill.com>2024-09-03 15:14:08 -0400
commit75b703236355de1ac2837828fdae9b6fdd198c28 (patch)
tree7f168ce768ae4bc5380105ccd5f672dcda8b41d0 /Makefile
parent82849ba783e2b8f8e3a040751cd964313470e7f2 (diff)
Show error output on test failure
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile7
1 files changed, 6 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index b636c8be..e9b901cd 100644
--- a/Makefile
+++ b/Makefile
@@ -47,7 +47,12 @@ tags:
$(CC) $(CFLAGS) -c $< -o $@
%.tm.testresult: %.tm tomo
- VERBOSE=0 COLOR=1 CC=gcc O=1 ./tomo $< 2>$@ >$@ && cat $@
+ @printf '\x1b[33;1;4m%s\x1b[m\n' $<
+ @set -o pipefail; \
+ if ! VERBOSE=0 COLOR=1 CC=gcc O=1 ./tomo $< 2>&1 | tee $@; then \
+ rm -f $@; \
+ false; \
+ fi
test: $(TESTS)
@echo -e '\x1b[32;7m ALL TESTS PASSED! \x1b[m'