bpo-45878: convert try/except to self.assertRaises in Lib/ctypes/test/test_functions.py#29721
Conversation
…/test/test_functions.py`
serhiy-storchaka
left a comment
There was a problem hiding this comment.
There may be reasons of using try/except instead of assertRaises() (the latter affects exception chaining and other subtle details), but in in this case using assertRaises() is correct and beneficial. It is not pure cosmetic change.
|
Thanks @sobolevn for the PR, and @serhiy-storchaka for merging it 🌮🎉.. I'm working now to backport this PR to: 3.9, 3.10. |
…/test/test_functions.py` (pythonGH-29721) (cherry picked from commit b48ac6f) Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
|
GH-29722 is a backport of this pull request to the 3.10 branch. |
…/test/test_functions.py` (pythonGH-29721) (cherry picked from commit b48ac6f) Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
|
GH-29723 is a backport of this pull request to the 3.9 branch. |
|
Thanks @sobolevn for the PR, and @serhiy-storchaka for merging it 🌮🎉.. I'm working now to backport this PR to: 3.10. |
|
Thanks @sobolevn for the PR, and @serhiy-storchaka for merging it 🌮🎉.. I'm working now to backport this PR to: 3.10. |
|
GH-29748 is a backport of this pull request to the 3.10 branch. |
…/test/test_functions.py` (pythonGH-29721) (cherry picked from commit b48ac6f) Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
…/test/test_functions.py` (pythonGH-29721)
https://bugs.python.org/issue45878