diff options
-rw-r--r-- | fuzzycat/verify.py | 2 | ||||
-rw-r--r-- | tests/data/release/kokj44xkcfhxvorj7cs7rov2ku | 44 | ||||
-rw-r--r-- | tests/data/release/qnblx3fetbegpe7ryt444dpkke | 21 | ||||
-rw-r--r-- | tests/data/release/s43ecmng5bbqzcqhxmo7wbfsma | 47 | ||||
-rw-r--r-- | tests/data/release/vrwrf372jbd2vbwcb6fllsvhae | 26 | ||||
-rw-r--r-- | tests/data/verify.csv | 6 |
6 files changed, 144 insertions, 2 deletions
diff --git a/fuzzycat/verify.py b/fuzzycat/verify.py index 76571da..9f5aa4f 100644 --- a/fuzzycat/verify.py +++ b/fuzzycat/verify.py @@ -324,6 +324,8 @@ def compare(a, b): return (Status.DIFFERENT, Miss.RELEASE_TYPE) if "dataset" in types and ("article" in types or "article-journal" in types): return (Status.DIFFERENT, Miss.RELEASE_TYPE) + if "book" in types and ("article" in types or "article-journal" in types): + return (Status.DIFFERENT, Miss.RELEASE_TYPE) except PathAccessError: pass diff --git a/tests/data/release/kokj44xkcfhxvorj7cs7rov2ku b/tests/data/release/kokj44xkcfhxvorj7cs7rov2ku new file mode 100644 index 0000000..9f6dd9d --- /dev/null +++ b/tests/data/release/kokj44xkcfhxvorj7cs7rov2ku @@ -0,0 +1,44 @@ +{ + "abstracts": [], + "container_id": "5idg4ohjqfggjd2vdgxino7424", + "contribs": [ + { + "extra": { + "seq": "first" + }, + "index": 0, + "raw_affiliation": "Haveratock Hill", + "raw_name": "C. A. Ward", + "role": "author" + } + ], + "ext_ids": { + "doi": "10.1093/nq/s6-x.243.147c" + }, + "extra": { + "crossref": { + "subject": [ + "Linguistics and Language", + "Literature and Literary Theory", + "Library and Information Sciences", + "Language and Linguistics" + ], + "type": "journal-article" + } + }, + "ident": "kokj44xkcfhxvorj7cs7rov2ku", + "issue": "243", + "language": "en", + "pages": "147-147", + "publisher": "Oxford University Press (OUP)", + "refs": [], + "release_date": "1884-08-23", + "release_stage": "published", + "release_type": "article-journal", + "release_year": 1884, + "revision": "a235ad3f-fdef-48d1-ae3e-c4cdab3bc83e", + "state": "active", + "title": "Dennis", + "volume": "s6-X", + "work_id": "3l3zxdptyzdqzfx4xwx5we6w5e" +} diff --git a/tests/data/release/qnblx3fetbegpe7ryt444dpkke b/tests/data/release/qnblx3fetbegpe7ryt444dpkke new file mode 100644 index 0000000..07396c6 --- /dev/null +++ b/tests/data/release/qnblx3fetbegpe7ryt444dpkke @@ -0,0 +1,21 @@ +{ + "abstracts": [], + "contribs": [], + "ext_ids": { + "doi": "10.1163/2405-8262_rgg4_sim_03544" + }, + "extra": { + "container_name": "Religion in Geschichte und Gegenwart", + "crossref": { + "type": "dataset" + } + }, + "ident": "qnblx3fetbegpe7ryt444dpkke", + "publisher": "Brill Academic Publishers", + "refs": [], + "release_type": "dataset", + "revision": "5ded3cec-84a3-48b0-8042-17e5a5f683e1", + "state": "active", + "title": "Dennis", + "work_id": "4yqrz4nibzbjrfkmrz3rcbitia" +} diff --git a/tests/data/release/s43ecmng5bbqzcqhxmo7wbfsma b/tests/data/release/s43ecmng5bbqzcqhxmo7wbfsma new file mode 100644 index 0000000..0c9a944 --- /dev/null +++ b/tests/data/release/s43ecmng5bbqzcqhxmo7wbfsma @@ -0,0 +1,47 @@ +{ + "abstracts": [], + "container_id": "tlbcf4zay5agfmghpe7enspjla", + "contribs": [ + { + "extra": { + "seq": "first" + }, + "index": 0, + "raw_name": "Lise M. Stevens", + "role": "author" + }, + { + "index": 1, + "raw_name": "Cassio Lynm", + "role": "author" + }, + { + "index": 2, + "raw_name": "Richard M. Glass", + "role": "author" + } + ], + "ext_ids": { + "doi": "10.1001/jama.292.9.1134", + "pmid": "15339902" + }, + "extra": { + "crossref": { + "type": "journal-article" + } + }, + "ident": "s43ecmng5bbqzcqhxmo7wbfsma", + "language": "en", + "pages": "1134", + "publisher": "American Medical Association (AMA)", + "refs": [], + "release_date": "2004-09-01", + "release_stage": "published", + "release_type": "article-journal", + "release_year": 2004, + "revision": "522679bf-adde-476b-9c96-8ccc936e8877", + "state": "active", + "title": "Academic Health Centers", + "volume": "292", + "work_id": "fxjwnfqtujcahjnxnoxwjo22ki" +} diff --git a/tests/data/release/vrwrf372jbd2vbwcb6fllsvhae b/tests/data/release/vrwrf372jbd2vbwcb6fllsvhae new file mode 100644 index 0000000..0aad5d2 --- /dev/null +++ b/tests/data/release/vrwrf372jbd2vbwcb6fllsvhae @@ -0,0 +1,26 @@ +{ + "abstracts": [], + "contribs": [], + "ext_ids": { + "doi": "10.17226/10734" + }, + "extra": { + "crossref": { + "type": "book" + }, + "subtitle": [ + "Leading Change in the 21st Century" + ] + }, + "ident": "vrwrf372jbd2vbwcb6fllsvhae", + "publisher": "National Academies Press", + "refs": [], + "release_date": "2004-06-03", + "release_stage": "published", + "release_type": "book", + "release_year": 2004, + "revision": "536d45af-0140-4374-9782-3e36d366ca45", + "state": "active", + "title": "Academic Health Centers", + "work_id": "4byx733gqrfn3kj7hnbutngbbi" +} diff --git a/tests/data/verify.csv b/tests/data/verify.csv index 4c5ebb8..d522904 100644 --- a/tests/data/verify.csv +++ b/tests/data/verify.csv @@ -39,7 +39,7 @@ fmeud4dykjfudb5kjr2fgmaneq,iid2bnrjjbegtpgmpuppjou4k4,Status.DIFFERENT,Miss.SUBT zmivcpjvhba25ldkx27d24oefa,mjapiqe2nzcy3fs3hriw253dye,Status.STRONG,OK.FIGSHARE_VERSION lynlkp7wh5hn3mlpzcfz4faoqi,yrbvjd4xrjaq3jxt7pkheysclm,Status.DIFFERENT,Miss.YEAR t3vpox5wrvbgtcigp6a6o64oey,q5yaj5zbzjctzapb5bztzctsoe,Status.DIFFERENT,Miss.YEAR -65qtai5dmjb2hmkwa73nwafyhu,p4lk4tbohjat3g5nn5pb3kjdyu,Status.DIFFERENT,Miss.YEAR +65qtai5dmjb2hmkwa73nwafyhu,p4lk4tbohjat3g5nn5pb3kjdyu,Status.DIFFERENT,Miss.RELEASE_TYPE fqtc2tonfbh7hlcwoxgxzqi4lu,ng7utp7murge3ksuzbtljf5bsq,Status.DIFFERENT,Miss.YEAR mbnr3nrdijerto6wfjnlsmfhga,ddikrsxnajblvchthiwcbsmiue,Status.STRONG,OK.DATACITE_RELATED_ID nqfv37as6bcohketfrhiuac2mq,ty6megtz35c3hep57bbx2cetja,Status.DIFFERENT,Miss.YEAR @@ -61,7 +61,7 @@ muk4xhjhubc3xn6qqddllgfsly,2gywie7yqfflnl6tljfo36keqi,Status.EXACT,OK.WORK_ID iywyis7npngxxbco6fgjrclrzy,anhsfjxg3few5nkfsvheehiebq,Status.DIFFERENT,Miss.BOOK_CHAPTER rk7mn5uaqjaslgcxc2nl6ijpaq,td3rnxzbxzeslj6ijoce3mtxcq,Status.EXACT,OK.WORK_ID ohkfrjjcxfcavoqoqt52wi6eke,egufgu3yubgthex3y7fdt7uupa,Status.DIFFERENT,Miss.DATASET_DOI -dklwsz4w3rdlfddif4pcxb6ngm,wsbinmv7lragjnaedbgws6bztm,Status.DIFFERENT,Miss.YEAR +dklwsz4w3rdlfddif4pcxb6ngm,wsbinmv7lragjnaedbgws6bztm,Status.DIFFERENT,Miss.RELEASE_TYPE jizydliu2vclvpdtcrajlvuq2m,3g6mdd3tvjabdaez6mwcycso3q,Status.EXACT,OK.WORK_ID fvrscdvsznb4zlhuadd6ar7ot4,57la45yryjd73gav22bnl4lyni,Status.STRONG,OK.FIGSHARE_VERSION 6fedywjyynbxhdqv3etxjuqhba,gls2x7ca4nhzrkf437gdnj6ekq,Status.DIFFERENT,Miss.YEAR @@ -155,3 +155,5 @@ gtsbvudmjzdeppqgzjpmfedycq,27lrseg7jfhxbdxohph7il7a7m,Status.DIFFERENT,Miss.JSTO a3kmwzn4kjerbingv7oyfs5gwe,4m6ijk5gu5gxhcbvd2f4i2xk5u,Status.DIFFERENT,Miss.RELEASE_TYPE 254alcrrgfcz7l6j6kce7xqoli,kix6fwgliffudepddlnflom6pq,Status.AMBIGUOUS, s5gvgub2nvhazb5w7qae7w2dki,ac5cwyrtljgtji3jfgw3s2ckfe,Status.AMBIGUOUS, +qnblx3fetbegpe7ryt444dpkke,kokj44xkcfhxvorj7cs7rov2ku,Status.DIFFERENT,Miss.RELEASE_TYPE +vrwrf372jbd2vbwcb6fllsvhae,s43ecmng5bbqzcqhxmo7wbfsma,Status.DIFFERENT,Miss.RELEASE_TYPE |