Page MenuHomeSoftware Heritage

Jenkins > .tox.py3.lib.python3.7.site-packages.swh.indexer.tests.test_metadata.TestMetadata::test_extrinsic_metadata_indexer_github
Failed

TEST RESULT

Run At
Jul 4 2022, 2:14 PM
Details
self = <swh.indexer.tests.test_metadata.TestMetadata object at 0x7fa401564518> mocker = <pytest_mock.plugin.MockerFixture object at 0x7fa3f81de668> def test_extrinsic_metadata_indexer_github(self, mocker): """Nominal case, calling the mapping and storing the result""" origin = "https://example.org/jdoe/myrepo" metadata_indexer = ExtrinsicMetadataIndexer(config=DIRECTORY_METADATA_CONFIG) metadata_indexer.catch_exceptions = False metadata_indexer.storage = mocker.patch.object(metadata_indexer, "storage") metadata_indexer.storage.origin_get_by_sha1.return_value = [{"url": origin}] tool = metadata_indexer.idx_storage.indexer_configuration_get( {f"tool_{k}": v for (k, v) in TRANSLATOR_TOOL.items()} ) assert tool is not None > assert metadata_indexer.process_journal_objects( {"raw_extrinsic_metadata": [REMD.to_dict()]} ) == {"status": "eventful", "origin_extrinsic_metadata:add": 1} .tox/py3/lib/python3.7/site-packages/swh/indexer/tests/test_metadata.py:210: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ .tox/py3/lib/python3.7/site-packages/swh/indexer/metadata.py:79: in process_journal_objects self.index(item["id"], data=RawExtrinsicMetadata.from_dict(item)) .tox/py3/lib/python3.7/site-packages/swh/indexer/metadata.py:120: in index if data.format in mapping.extrinsic_metadata_formats(): _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ cls = <class 'swh.indexer.metadata_dictionary.composer.ComposerMapping'> @classmethod def extrinsic_metadata_formats(cls) -> Tuple[str, ...]: """ Returns the list of extrinsic metadata formats which can be translated by this mapping """ > raise NotImplementedError(f"{cls.__name__}.extrinsic_metadata_formats") E NotImplementedError: ComposerMapping.extrinsic_metadata_formats .tox/py3/lib/python3.7/site-packages/swh/indexer/metadata_dictionary/base.py:77: NotImplementedError