diff --git a/src/calibre/ebooks/metadata/sources/identify.py b/src/calibre/ebooks/metadata/sources/identify.py index b494e05e1a..170ceb6c7a 100644 --- a/src/calibre/ebooks/metadata/sources/identify.py +++ b/src/calibre/ebooks/metadata/sources/identify.py @@ -395,8 +395,8 @@ if __name__ == '__main__': # tests {{{ # unknown to Amazon {'identifiers':{'isbn': '9780307459671'}, 'title':'Invisible Gorilla', 'authors':['Christopher Chabris']}, - [title_test('The Invisible Gorilla: And Other Ways Our Intuitions Deceive Us', - exact=True), authors_test(['Christopher Chabris', 'Daniel Simons'])] + [title_test('The Invisible Gorilla', + exact=True), authors_test(['Christopher F. Chabris', 'Daniel Simons'])] ), @@ -404,7 +404,7 @@ if __name__ == '__main__': # tests {{{ {'title':'Learning Python', 'authors':['Lutz']}, [title_test('Learning Python', - exact=True), authors_test(['Mark Lutz']) + exact=True), authors_test(['Mark J. Lutz', 'David Ascher']) ] ), diff --git a/src/calibre/ebooks/metadata/sources/test.py b/src/calibre/ebooks/metadata/sources/test.py index 2e72f86c47..284a7ba45e 100644 --- a/src/calibre/ebooks/metadata/sources/test.py +++ b/src/calibre/ebooks/metadata/sources/test.py @@ -218,11 +218,11 @@ def test_identify_plugin(name, tests): # {{{ '')+'-%s-cover.jpg'%sanitize_file_name2(mi.title.replace(' ', '_'))) with open(cover, 'wb') as f: - f.write(cdata) + f.write(cdata[-1]) prints('Cover downloaded to:', cover) - if len(cdata) < 10240: + if len(cdata[-1]) < 10240: prints('Downloaded cover too small') raise SystemExit(1)