Kami commented on code in PR #2014:
URL: https://github.com/apache/libcloud/pull/2014#discussion_r1632009989
##########
libcloud/test/__init__.py:
##########
@@ -97,6 +97,8 @@ class MockHttp(LibcloudConnection):
(int status, str body, dict headers, str reason)
"""
+ # pytest may collect this class, and we don't need or want that
+ __test__ = False
Review Comment:
Thanks for the contribution.
As @RonnyPfannschmidt pointed out, that will break a bunch of tests which
have assertions directly in subclassed MockHttp class (I believe there are
quite a few of those).
---
On a related note, pytest 8.0.x also broke a bunch of other tests recently
due to the changes in the test loading / discovery mechanism
(https://github.com/apache/libcloud/pull/1994). I battle for quite a while to
get everything to pass.
Granted, in that specific case, one of the main issues was cross test
pollution. Tests would only fail when they ran in a very specific order and
that's why we didn't detect that issue earlier and it was hard to track down
and fix.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]