From: Christian Herdtweck Date: Tue, 12 Feb 2019 10:30:37 +0000 (+0100) Subject: Make unittest output less distracting X-Git-Tag: v1.5~9 X-Git-Url: http://developer.intra2net.com/git/?a=commitdiff_plain;h=a6465fa3e5e89b17aeae44dd4b3378f0aade4a29;p=pyi2ncommon Make unittest output less distracting That blinking really catches my eye every time, quite distracting. Also limit output to a single line. --- diff --git a/test/test_text_helpers.py b/test/test_text_helpers.py index adc3daa..f341aad 100644 --- a/test/test_text_helpers.py +++ b/test/test_text_helpers.py @@ -39,9 +39,10 @@ class TextHelpersTester(unittest.TestCase): """ tests whether color functions do not raise errors """ for color in COLOR_BLACK, COLOR_RED, COLOR_GREEN, COLOR_YELLOW, \ COLOR_BLUE, COLOR_MAGENTA, COLOR_CYAN, COLOR_WHITE: - exec('{0}("{0}")'.format(color)) - for style in 'normal', 'bold', 'underline', 'blink', 'reverse': - exec('{0}("{0}")'.format(style)) + exec('{0}("{0}", end=", ")'.format(color)) + for style in 'normal', 'bold', 'underline', 'reverse': + exec('{0}("{0}", end=", ")'.format(style)) + # leave out style 'blink' since it is just too distracting def test_shortening(self): """ test function head_and_tail """