Unittest - Use stderr for diagnostics too

This commit is contained in:
Renato Alves 2014-07-18 19:22:48 +01:00
parent a88b3be093
commit 97d490e0fd

View file

@ -8,10 +8,10 @@ from .taskd import Taskd
class BaseTestCase(unittest.TestCase):
def diag(self, out):
sys.stdout.write("# --- diag start ---\n")
sys.stderr.write("# --- diag start ---\n")
for line in out.split("\n"):
sys.stdout.write("# " + line + "\n")
sys.stdout.write("# --- diag end ---\n")
sys.stderr.write("# " + line + "\n")
sys.stderr.write("# --- diag end ---\n")
@unittest.skipIf(TASKW_SKIP, "TASKW_SKIP set, skipping task tests.")