-
-
Notifications
You must be signed in to change notification settings - Fork 437
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
running unittest with coverage fails with Pypy 3.10 for some tests #1902
Comments
see also: nedbat/coveragepy#1902 Bug: T380732 Change-Id: I3a8942e91ef3a30f4b4fe80392030bd88c82040a
When I try to run your command
I see the .sample, and the pwb.py tool, but running them starts asking me questions I don't know the answer to. Please provide complete instructions for me to reproduce the failure. |
Trying a little harder to make a user-config.py file, I get:
|
Hi @nedbat: The content of user-config.py file does not care for the test, so you just can rename the given
But be aware: the test fails for pypy3.10 only so you have to install it first and the dependencies is needed for it. |
Thanks, those details made it reproducible for me. I have no idea what's going wrong, but |
This is now fixed in commit 80a479d. |
Great job, thank you. |
This is now released as part of coverage 7.6.10. |
Describe the bug
running unittest with coverage > 7.6.1 fails with pypy 3.10 for some tests. It works with coverage 7.6.1 and below
To Reproduce
What version of Python are you using?
-> pypy 3.10
Python: 3.10.14 (39dc8d3c85a7, Aug 27 2024, 14:32:27)
[PyPy 7.3.17 with GCC 10.2.1 20210130 (Red Hat 10.2.1-11)]
What version of coverage.py shows the problem?
-> 7.6.2 - 7.6.9
What versions of what packages do you have installed?
-> see https://github.com/wikimedia/pywikibot/actions/runs/12211147365/job/34068904767 for example
What code shows the problem?
-> The specific test failing is this:
@patch('builtins.import', side_effect=ImportError, autospec=True)
class TestNoBeautifulSoup(TestCase):
The code can be found here:
https://github.com/wikimedia/pywikibot/blob/master/tests/diff_tests.py
The shown problem is
-> coverage run -m unittest discover -vv -p "*_tests.py";
Expected behavior
Test should run like it does with coverage 7.6.1
Additional context
The text was updated successfully, but these errors were encountered: