self = <swh.storage.tests.test_cassandra.TestCassandraStorage object at 0x7f42000960f0>
swh_storage = <swh.storage.cassandra.storage.CassandraStorage object at 0x7f42001c5e10>
sample_data = <swh.storage.tests.storage_data.StorageData object at 0x7f42002873c8>
def test_directory_add_from_generator(self, swh_storage, sample_data):
directory = sample_data.directories[1]
def _dir_gen():
yield directory
actual_result = swh_storage.directory_add(directories=_dir_gen())
assert actual_result == {"directory:add": 1}
> assert list(swh_storage.journal_writer.journal.objects) == [
("directory", directory)
]
E AssertionError: assert [] == [('directory'...c3\x96\xbe'))]
E Right contains one more item: ('directory', Directory(entries=(DirectoryEntry(name=b'foo', type='file', target=b'\xd8\x1c\xc0q\x0e\xb6\xcf\x9e\xfd[\...x04', perms=<DentryPerms.directory: 16384>)), id=b'4\xf35\xa7P\x11\x1c\xa0\xa8\xb6M\x804\xfa\xec\x9e\xed\xc3\x96\xbe'))
E Full diff:
E [
E + ,
E - ('directory',
E - Directory(entries=(DirectoryEntry(name=b'foo', type='file', target=b'\xd8\x1c\xc0q\x0e\xb6\xcf\x9e\xfd[\x92\n\x84S\xe1\xe0qW\xb6\xcd', perms=<DentryPerms.content: 33188>), DirectoryEntry(name=b'bar\xc3', type='dir', target=b'K\x82]\xc6B\xcbn\xb9\xa0`\xe5K\xf8\xd6\x92\x88\xfb\xeeI\x04', perms=<Den...
E
E ...Full output truncated (2 lines hidden), use '-vv' to show
.tox/py3/lib/python3.7/site-packages/swh/storage/tests/test_storage.py:689: AssertionError
TEST RESULT
TEST RESULT
- Run At
- Jul 29 2020, 10:34 AM