From 68cfc6f551a02d29a2bc48c6473fad6ab42a476f Mon Sep 17 00:00:00 2001 From: Michael J Gruber Date: Tue, 8 Dec 2009 11:12:02 +0100 Subject: t7508-status: test all modes with color Move a useful script function to decode colored output to text form from t4034 and use it in this test as well. Signed-off-by: Michael J Gruber Signed-off-by: Junio C Hamano --- t/test-lib.sh | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 't/test-lib.sh') diff --git a/t/test-lib.sh b/t/test-lib.sh index 5fdc5d94a2..d63ad2d870 100644 --- a/t/test-lib.sh +++ b/t/test-lib.sh @@ -208,6 +208,17 @@ test_set_editor () { export VISUAL } +test_decode_color () { + sed -e 's/.\[1m//g' \ + -e 's/.\[31m//g' \ + -e 's/.\[32m//g' \ + -e 's/.\[33m//g' \ + -e 's/.\[34m//g' \ + -e 's/.\[35m//g' \ + -e 's/.\[36m//g' \ + -e 's/.\[m//g' +} + test_tick () { if test -z "${test_tick+set}" then -- cgit v1.2.1