Skip to content

Commit c083bc2

Browse files
committed
avoid travis log output buffering issue
1 parent 2afb00c commit c083bc2

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

tests/lib/prove.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131

3232
import base64
3333
import os
34+
import time
3435
import zlib
3536

3637
from .const import (
@@ -123,7 +124,10 @@ def prove(self, test_path):
123124
print('len_expected = {:d}\nlen_passed = {:d}\nlen_passed_todo = {:d}\nlen_failed = {:d}\nlen_failed_todo = {:d}'.format(
124125
len_expected, len_passed, len_passed_todo, len_failed, len_failed_todo
125126
))
126-
print(base64.encodebytes(zlib.compress(report_str.encode('utf-8'), 7)).decode('utf-8')) # compress level 7 (high)
127+
report_str = base64.encodebytes(zlib.compress(report_str.encode('utf-8'), 7)).decode('utf-8') # compress level 7 (high)
128+
for line in report_str.split('\n'):
129+
print(line)
130+
time.sleep(0.002) # HACK avoid Travis buffering issues
127131

128132
self.__clear_loggedfs_log__()
129133

0 commit comments

Comments
 (0)