3 ms·
I've been a long time nosetests user, but it's become unmaintained, so I'd like to migrate something else. pytest seems to be an obvious choice, but I really di
by jwilk 9y ago
I've been a long time nosetests user, but it's become unmaintained, so I'd like to migrate something else. pytest seems to be an obvious choice, but I really dislike the way it formats test failures. Is there a way to make it use a more traditional format?
- JustSomeNobody 9y agoIs nose buggy or is it missing features you need?
- Alex3917 9y agoNose is buggy. Lots of memory leaks, things that don't work in parallel, etc.
- jeremya 9y agoYes, you can alter the way tracebacks are printed (or not printed) for test failures: https://docs.pytest.org/en/latest/usage.html#modifying-python-traceback-printing https://docs.pytest.org/en/latest/usage.html#modifying-pytho...
- jwilk 9y agoThanks! --tb=native combined with --color=no makes it almost bearable. It still annoys me that ==================================================================================== FAILURES ===================================================================================== takes the whole screen width. I can pipe stdout through "cat" to fix it, but it's not very convenient.
- variedthoughts 9y agoTry -q
- quodlibetor 9y agoInteresting. pytest's handling of `assert foo == bar` is one of my top two favorite things about it. My other favorite thing being fixtures.
- drcongo 9y agoThis is probably not to your taste, but I _love_ it: https://pivotfinland.com/pytest-sugar/ https://pivotfinland.com/pytest-sugar/