We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
My test looks like this.
import pytest @pytest.fixture def foo(): yield print("foo") raise ValueError("foo") @pytest.fixture def bar(): yield print("bar") raise ValueError("foo") def test_foo(foo, bar): pass
And it gives me this output:
======================= test session starts ======================= platform linux -- Python 3.6.9[pypy-7.3.1-final], pytest-6.0.1, py-1.9.0, pluggy-0.13.0 rootdir: /home/ppodusowski/Playground/pytest-fixtures plugins: asyncio-0.14.0, flakefinder-1.0.0, timeout-1.4.2 collected 1 item test_foo.py .E [100%] ============================= ERRORS ============================== __________________ ERROR at teardown of test_foo __________________ @pytest.fixture def bar(): yield print("bar") > raise ValueError("foo") E ValueError: foo test_foo.py:13: ValueError -------------------- Captured stdout teardown --------------------- bar foo ===================== short test summary info ===================== ERROR test_foo.py::test_foo - ValueError: foo =================== 1 passed, 1 error in 0.26s ====================
So despite both finalizers being called, exception from only one of them is reported. Apparently the issue is known.
The text was updated successfully, but these errors were encountered:
You are correct. This issue is a duplicate of #8217, so I'll close this one.
Sorry, something went wrong.
No branches or pull requests
My test looks like this.
And it gives me this output:
So despite both finalizers being called, exception from only one of them is reported. Apparently the issue is known.
The text was updated successfully, but these errors were encountered: