-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Closed
Labels
plugin: capturerelated to the capture builtin pluginrelated to the capture builtin plugintype: enhancementnew feature or API change, should be merged into features branchnew feature or API change, should be merged into features branch
Description
This code mimics Python code with lots of stdout output:
def test_test():
print 'bla bla bla\n' * 10
assert False, 'something failed'
Running pytest with --tb=short
, I get the following output:
================= test session starts ==================
platform linux2 -- Python 2.7.9 -- py-1.4.31 -- pytest-2.6.4
plugins:
collected 1 items
test_test.py F
======================= FAILURES =======================
______________________ test_test _______________________
test_test.py:5: in test_test
assert False, 'something failed'
E AssertionError: something failed
E assert False
----------------- Captured stdout call -----------------
bla bla bla
bla bla bla
bla bla bla
bla bla bla
bla bla bla
bla bla bla
bla bla bla
bla bla bla
bla bla bla
bla bla bla
=============== 1 failed in 0.02 seconds ===============
It would be helpful if I could disable the sections "captured stdout/err call", e.g. with --capture=hide
, especially as our code prints hundreds of lines usually. The additional information that --tb=short
gives over --tb=line
however is very useful for understanding where problems come from.
degustaf, aaaidan, odarbelaeze, Mattemagikern, xverges and 9 more
Metadata
Metadata
Assignees
Labels
plugin: capturerelated to the capture builtin pluginrelated to the capture builtin plugintype: enhancementnew feature or API change, should be merged into features branchnew feature or API change, should be merged into features branch