From 929f6d1020362a8065d1e0c95d2ee67c88f89b33 Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Wed, 23 Mar 2022 18:54:42 -0700 Subject: fix typo in fileset comparison helper --- python/fatcat_tools/importers/common.py | 2 +- python/tests/import_ingest.py | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) (limited to 'python') diff --git a/python/fatcat_tools/importers/common.py b/python/fatcat_tools/importers/common.py index 475cb97a..2136d1da 100644 --- a/python/fatcat_tools/importers/common.py +++ b/python/fatcat_tools/importers/common.py @@ -926,4 +926,4 @@ def filesets_very_similar(a: FilesetEntity, b: FilesetEntity) -> bool: """ a_hashes = set([f.sha1 for f in a.manifest]) b_hashes = set([f.sha1 for f in b.manifest]) - return a == b + return a_hashes == b_hashes diff --git a/python/tests/import_ingest.py b/python/tests/import_ingest.py index d86d6d7b..44dd5a0b 100644 --- a/python/tests/import_ingest.py +++ b/python/tests/import_ingest.py @@ -235,7 +235,6 @@ def test_ingest_fileset_importer(ingest_fileset_importer): counts = JsonLinePusher(ingest_fileset_importer, f).run() assert counts["insert"] == 0 - assert counts["exists"] == 0 - assert counts["skip"] == 20 + assert counts["exists"] == 7 + assert counts["skip"] == 13 assert counts["skip-release-not-found"] == 13 - assert counts["skip-release-has-fileset"] == 7 -- cgit v1.2.3