self = <swh.storage.tests.test_cassandra.TestCassandraStorage object at 0x7f9174b79438>
swh_storage_backend_config = {'cls': 'cassandra', 'hosts': ['127.0.0.1'], 'journal_writer': {'cls': 'memory'}, 'keyspace': 'b450d37fedbc10b9b0a7', ...}
def test_config_consistency_used(self, swh_storage_backend_config):
config_with_consistency = dict(
swh_storage_backend_config, **{"consistency_level": "ONE"}
)
storage = get_storage(**config_with_consistency)
with pytest.raises(NoHostAvailable):
> storage.content_get_random()
.tox/py3/lib/python3.7/site-packages/swh/storage/tests/test_cassandra.py:263:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <swh.storage.cassandra.storage.CassandraStorage object at 0x7f9175455828>
def content_get_random(self) -> Sha1Git:
content = self._cql_runner.content_get_random()
> assert content, "Could not find any content"
E AssertionError: Could not find any content
E assert None
.tox/py3/lib/python3.7/site-packages/swh/storage/cassandra/storage.py:375: AssertionError
TEST RESULT
TEST RESULT
- Run At
- Jul 6 2021, 5:13 PM