Add updated file
This commit is contained in:
parent
9bfeb3375c
commit
4c16dca865
|
@ -926,7 +926,7 @@ def test_store_except_info_on_error() -> None:
|
||||||
# Check that exception info is stored on sys
|
# Check that exception info is stored on sys
|
||||||
assert sys.last_type is IndexError
|
assert sys.last_type is IndexError
|
||||||
assert isinstance(sys.last_value, IndexError)
|
assert isinstance(sys.last_value, IndexError)
|
||||||
if sys.version_info >= (3,12,0):
|
if sys.version_info >= (3, 12, 0):
|
||||||
assert isinstance(sys.last_exc, IndexError)
|
assert isinstance(sys.last_exc, IndexError)
|
||||||
|
|
||||||
assert sys.last_value.args[0] == "TEST"
|
assert sys.last_value.args[0] == "TEST"
|
||||||
|
@ -937,7 +937,7 @@ def test_store_except_info_on_error() -> None:
|
||||||
runner.pytest_runtest_call(ItemMightRaise()) # type: ignore[arg-type]
|
runner.pytest_runtest_call(ItemMightRaise()) # type: ignore[arg-type]
|
||||||
assert not hasattr(sys, "last_type")
|
assert not hasattr(sys, "last_type")
|
||||||
assert not hasattr(sys, "last_value")
|
assert not hasattr(sys, "last_value")
|
||||||
if sys.version_info >= (3,12,0):
|
if sys.version_info >= (3, 12, 0):
|
||||||
assert not hasattr(sys, "last_exc")
|
assert not hasattr(sys, "last_exc")
|
||||||
assert not hasattr(sys, "last_traceback")
|
assert not hasattr(sys, "last_traceback")
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue