Nicer linebreaking in _render_log
This commit is contained in:
parent
469c75662e
commit
38a3d118ab
@ -80,9 +80,8 @@ def _render_log(data, threshold=100):
|
||||
data = [str(d) for d in data]
|
||||
is_exception = any('Traceback (most recent call last):' in line
|
||||
for line in data)
|
||||
if (len(data) > threshold and
|
||||
not pytest.config.getoption('--verbose') and
|
||||
not is_exception):
|
||||
verbose = pytest.config.getoption('--verbose')
|
||||
if len(data) > threshold and not verbose and not is_exception:
|
||||
msg = '[{} lines suppressed, use -v to show]'.format(
|
||||
len(data) - threshold)
|
||||
data = [msg] + data[-threshold:]
|
||||
|
Loading…
Reference in New Issue
Block a user