avoid importing old assertion interpretation code by default (fixes #537)
This commit is contained in:
parent
80ad3fb8ed
commit
dc65aa1fea
|
@ -1,6 +1,8 @@
|
|||
NEXT (2.6)
|
||||
-----------------------------------
|
||||
|
||||
- fix issue537: Avoid importing old assertion reinterpretation code by default.
|
||||
|
||||
- fix issue364: shorten and enhance tracebacks representation by default.
|
||||
The new "--tb=auto" option (default) will only display long tracebacks
|
||||
for the first and last entry. You can get the old behaviour of printing
|
||||
|
|
|
@ -45,10 +45,8 @@ class AssertionError(BuiltinAssertionError):
|
|||
|
||||
if sys.version_info > (3, 0):
|
||||
AssertionError.__module__ = "builtins"
|
||||
reinterpret_old = "old reinterpretation not available for py3"
|
||||
else:
|
||||
from _pytest.assertion.oldinterpret import interpret as reinterpret_old
|
||||
|
||||
if sys.version_info >= (2, 6) or (sys.platform.startswith("java")):
|
||||
from _pytest.assertion.newinterpret import interpret as reinterpret
|
||||
else:
|
||||
reinterpret = reinterpret_old
|
||||
from _pytest.assertion.oldinterpret import interpret as reinterpret
|
||||
|
|
Loading…
Reference in New Issue