-
Notifications
You must be signed in to change notification settings - Fork 6
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
Python 3.11: test_report_gives_package_version fails #94
Comments
Thanks @musicinmybrain for opening this issue! |
Please see: python/cpython#98771 Just modifying the patching order solves the problem: -@patch("builtins.print")
@patch("importlib.import_module")
-def test_report_gives_package_version(mock_import_module, mock_print):
+@patch("builtins.print")
+def test_report_gives_package_version(mock_print, mock_import_module):
module = TestModule()
mock_import_module.return_value = module Kind Regards |
musicinmybrain
added a commit
to musicinmybrain/pyct
that referenced
this issue
Jan 28, 2023
Thanks for tying these two issues together. I’ll open a PR. |
musicinmybrain
added a commit
to musicinmybrain/pyct
that referenced
this issue
Jan 28, 2023
musicinmybrain
added a commit
to musicinmybrain/pyct
that referenced
this issue
Jan 28, 2023
maximlt
pushed a commit
that referenced
this issue
Jan 30, 2023
* Ensure tox envs that run tests depend on cmd extra * Fix test_report_gives_package_version on Python 3.11+ Fixes #94. See python/cpython#98771 and #94 (comment). * Add missing newline at end of pyct/tests/test_report.py * Test Python 3.11 and add it to the trove classifiers
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
On Python 3.11b3 (pre-release),
test_report_gives_package_version
fails. In a quick investigation, it wasn’t obvious to me what to do about it.It seems like the actual library is working as expected, and this is a test/mocking issue:
The text was updated successfully, but these errors were encountered: