swh_storage = <swh.storage.in_memory.InMemoryStorage object at 0x7fb63773d5f8>
def test_snapshot_resolve_alias_dangling_branch(swh_storage):
dangling_branch_name = b"dangling_branch"
alias_name = b"rev_alias"
alias_branch = SnapshotBranch(
target=dangling_branch_name, target_type=TargetType.ALIAS
)
snapshot = Snapshot(
branches={dangling_branch_name: None, alias_name: alias_branch,}
)
> swh_storage.snapshot_add([snapshot])
.tox/py3/lib/python3.7/site-packages/swh/storage/tests/algos/test_snapshot.py:355:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <swh.storage.in_memory.InMemoryStorage object at 0x7fb63773d5f8>
snapshots = [Snapshot(branches=ImmutableDict({b'dangling_branch': None, b'rev_alias': SnapshotBranch(target=b'dangling_branch', target_type=<TargetType.ALIAS: 'alias'>)}), id=b'\\\x81\xc2\x7f\x00"gKR.\x80\xc9\xba \xf1)2\x9b&\xbd')]
def snapshot_add(self, snapshots: List[Snapshot]) -> Dict:
> if self._check_missing:
E AttributeError: 'InMemoryStorage' object has no attribute '_check_missing'
.tox/py3/lib/python3.7/site-packages/swh/storage/cassandra/storage.py:665: AttributeError
TEST RESULT
TEST RESULT
- Run At
- Apr 22 2021, 8:33 PM