After the changes in PYTHON-1026, the tests no longer pass when there is no MongoDB cluster running:
ERROR: test_replica_set_client (unittest2.loader.ModuleImportFailure) ---------------------------------------------------------------------- ImportError: Failed to import test module: test_replica_set_client Traceback (most recent call last): File "/Users/shane/git/mongo-python-driver/.eggs/unittest2-0.8.0-py2.6.egg/unittest2/loader.py", line 445, in _find_test_path module = self._get_module_from_name(name) File "/Users/shane/git/mongo-python-driver/.eggs/unittest2-0.8.0-py2.6.egg/unittest2/loader.py", line 384, in _get_module_from_name __import__(name) File "/Users/shane/git/mongo-python-driver/test/test_replica_set_client.py", line 83, in <module> class TestReplicaSetClient(TestReplicaSetClientBase): File "/Users/shane/git/mongo-python-driver/test/test_replica_set_client.py", line 163, in TestReplicaSetClient @client_context.require_secondaries_count(1) File "/Users/shane/git/mongo-python-driver/test/__init__.py", line 378, in require_secondaries_count sec_count = len(self.client.secondaries) AttributeError: 'NoneType' object has no attribute 'secondaries'
- duplicates
-
PYTHON-1216 Failing unit tests on Debian - AttributeError: 'NoneType' object has no attribute 'secondaries'
- Closed