From 9986fee00e083c4f30e0da1be80de4a10d6d0632 Mon Sep 17 00:00:00 2001 From: Vincent Driessen Date: Sun, 5 Feb 2012 09:14:40 +0100 Subject: [PATCH] Pass test output through rg. --- run_tests | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/run_tests b/run_tests index 16daba5..4ac4f7e 100755 --- a/run_tests +++ b/run_tests @@ -4,8 +4,15 @@ check_redis_running() { return $? } +if which -s rg; then + safe_rg=rg +else + # Fall back for systems that don't have rg installed + safe_rg=cat +fi + if check_redis_running; then - /usr/bin/env python -m unittest discover -v -s tests $@ 2>&1 | egrep -v '^test_' + /usr/bin/env python -m unittest discover -v -s tests $@ 2>&1 | egrep -v '^test_' | $safe_rg else echo "Redis not running." >&2 exit 2