From: Stephen Hemminger Date: Mon, 12 Nov 2018 16:39:32 +0000 (-0800) Subject: testsuite: colorize test result output X-Git-Tag: v5.0.0~104^2~1 X-Git-Url: https://git.proxmox.com/?p=mirror_iproute2.git;a=commitdiff_plain;h=7e2f71b431bbde1d040a524731e9b210fd905de2 testsuite: colorize test result output When running testsuite it is easy as a human to miss failure. Add symbol colorizing to SKIPED/PASS/FAIL output. Signed-off-by: Stephen Hemminger --- diff --git a/testsuite/Makefile b/testsuite/Makefile index b3aebec1..46b243b0 100644 --- a/testsuite/Makefile +++ b/testsuite/Makefile @@ -85,11 +85,11 @@ endif TC="$$i/tc/tc" IP="$$i/ip/ip" SS=$$i/misc/ss DEV="$(DEV)" IPVER="$@" SNAME="$$i" \ ERRF="$(RESULTS_DIR)/$@.$$o.err" $(PREFIX) tests/$@ > $(RESULTS_DIR)/$@.$$o.out; \ if [ "$$?" = "127" ]; then \ - echo "SKIPPED"; \ + echo "\e[1;35mSKIPPED\e[0m"; \ elif [ -e "$(RESULTS_DIR)/$@.$$o.err" ]; then \ - echo "FAILED"; \ + echo "\e[0;31mFAILED\e[0m"; \ else \ - echo "PASS"; \ + echo "\e[0;32mPASS\e[0m"; \ fi; \ rm "$$TMP_ERR" "$$TMP_OUT"; \ sudo dmesg > $(RESULTS_DIR)/$@.$$o.dmesg; \