This module handles terminal interaction including ANSI color codes.
"""
+from __future__ import print_function
+
import os
import sys
if colour:
col = Color()
text = col.Color(colour, text)
- print text,
+ print(text, end='')
if newline:
- print
+ print()
+ else:
+ sys.stdout.flush()
def SetPrintTestMode():
"""Go into test mode, where all printing is recorded"""
for line in print_test_list:
if line.colour:
col = Color()
- print col.Color(line.colour, line.text),
+ print(col.Color(line.colour, line.text), end='')
else:
- print line.text,
+ print(line.text, end='')
if line.newline:
- print
+ print()
class Color(object):