Page MenuHomeSoftware Heritage

Jenkins > .tox.py3.lib.python3.7.site-packages.swh.indexer.tests.metadata_dictionary.test_npm::test_detect_metadata_package_json[PACKAGE.JSON]
Failed

TEST RESULT

Run At
Jul 4 2022, 2:14 PM
Details
filename = b'PACKAGE.JSON' @pytest.mark.parametrize( "filename", [b"package.json", b"Package.json", b"PACKAGE.json", b"PACKAGE.JSON"] ) def test_detect_metadata_package_json(filename): df = [ { "sha1_git": b"abc", "name": b"index.js", "target": b"abc", "length": 897, "status": "visible", "type": "file", "perms": 33188, "dir_id": b"dir_a", "sha1": b"bcd", }, { "sha1_git": b"aab", "name": filename, "target": b"aab", "length": 712, "status": "visible", "type": "file", "perms": 33188, "dir_id": b"dir_a", "sha1": b"cde", }, ] > results = detect_metadata(df) .tox/py3/lib/python3.7/site-packages/swh/indexer/tests/metadata_dictionary/test_npm.py:319: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ .tox/py3/lib/python3.7/site-packages/swh/indexer/metadata_detector.py:25: in detect_metadata matches = mapping.detect_metadata_files(files) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ cls = <class 'swh.indexer.metadata_dictionary.composer.ComposerMapping'> file_entries = [{'dir_id': b'dir_a', 'length': 897, 'name': b'index.js', 'perms': 33188, ...}, {'dir_id': b'dir_a', 'length': 712, 'name': b'PACKAGE.JSON', 'perms': 33188, ...}] @classmethod def detect_metadata_files(cls, file_entries: List[DirectoryLsEntry]) -> List[Sha1]: """ Returns the sha1 hashes of files which can be translated by this mapping """ > raise NotImplementedError(f"{cls.__name__}.detect_metadata_files") E NotImplementedError: ComposerMapping.detect_metadata_files .tox/py3/lib/python3.7/site-packages/swh/indexer/metadata_dictionary/base.py:69: NotImplementedError