self = <swh.indexer.tests.test_mimetype.TestMimetypeIndexer testMethod=test_index_one_unknown_sha1>
def test_index_one_unknown_sha1(self):
"""Unknown sha1 are not indexed"""
sha1s = [
self.id1,
"799a5ef812c53907562fe379d4b3851e69c7cb15", # unknown
"800a5ef812c53907562fe379d4b3851e69c7cb15",
] # unknown
# when
self.indexer.run(sha1s)
# then
expected_results = [res for res in self.expected_results if res.id in sha1s]
> self.assert_results_ok(sha1s, expected_results)
.tox/py3/lib/python3.7/site-packages/swh/indexer/tests/utils.py:736:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
.tox/py3/lib/python3.7/site-packages/swh/indexer/tests/utils.py:706: in assert_results_ok
self.assertEqual(expected_results, actual_results)
E AssertionError: Lists differ: [Cont[48 chars]ol={'configuration': {'type': 'library', 'debi[212 chars]ii')] != [Cont[48 chars]ol={'id': 2889608893489474361, 'name': 'file',[205 chars]ii')]
E
E First differing element 0:
E Conte[47 chars]ol={'configuration': {'type': 'library', 'debi[211 chars]cii')
E Conte[47 chars]ol={'id': 2889608893489474361, 'name': 'file',[204 chars]cii')
E
E - [ContentMimetypeRow(indexer_configuration_id=None, tool={'configuration': {'type': 'library', 'debian-package': 'python3-magic'}, 'version': '1:5.30-1+deb9u1', 'name': 'file', 'id': 2889608893489474361}, id=b'\x0fu\xaeO}u\xd4.\x12\xc1\xb6W!\xec\xae^v\xfe\xe2#', mimetype='text/x-script.python', encoding='us-ascii')]
E + [ContentMimetypeRow(indexer_configuration_id=None, tool={'id': 2889608893489474361, 'name': 'file', 'version': '1:5.30-1+deb9u1', 'configuration': {'type': 'library', 'debian-package': 'python3-magic'}}, id=b'\x0fu\xaeO}u\xd4.\x12\xc1\xb6W!\xec\xae^v\xfe\xe2#', mimetype='text/x-python', encoding='us-ascii')]
TEST RESULT
TEST RESULT
- Run At
- Jul 22 2022, 10:11 AM