New issue
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
tests: pytest doesn't fail for unhandled exceptions in signal handlers #2705
Labels
Milestone
Comments
lazka
added a commit
that referenced
this issue
Jan 9, 2018
The test doesn't actually work due to #2705
lazka
added a commit
to lazka/quodlibet
that referenced
this issue
Jan 9, 2018
…on an reraise them. Fixes quodlibet#2705 Exceptions raised during signals don't bubble to the test caller, instead they get pushed into sys.excepthook which by default prints them. This adds a pytest plugin which wraps each test (I think..) collects uncaught exceptions and reraises them at the end. This uncovers a few bugs, so this makes the tests fail atm.
9 tests are failing due to this, better look at it before 4.0.1 |
Cool. I've noticed this problem a couple of times too actually - adding a test that "fails" but only if you look at debug logs a lot... |
lazka
added a commit
that referenced
this issue
Jan 10, 2018
tests: capture exceptions that are not caught during the test execution an reraise them. Fixes #2705
lazka
added a commit
that referenced
this issue
Jan 10, 2018
The test doesn't actually work due to #2705
lazka
added a commit
that referenced
this issue
Jan 10, 2018
…on an reraise them. Fixes #2705 Exceptions raised during signals don't bubble to the test caller, instead they get pushed into sys.excepthook which by default prints them. This adds a pytest plugin which wraps each test (I think..) collects uncaught exceptions and reraises them at the end. This uncovers some bugs in the playlistbrowser tests. Most of the inherited tests were failing, and I think they never passed, so just remove the inheritance.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
pyqt has something to make it work: https://pytest-qt.readthedocs.io/en/2.3.1/virtual_methods.html
also pytest-dev/pytest#73
The text was updated successfully, but these errors were encountered: