aboutsummaryrefslogtreecommitdiffstats
path: root/test/test_results.py
diff options
context:
space:
mode:
authorLibravatarUnit 193 <unit193@ubuntu.com>2020-01-21 01:08:43 -0500
committerLibravatarUnit 193 <unit193@ubuntu.com>2020-01-21 01:08:43 -0500
commit4366125d2580982abb57bc65a26fc1fb8ef2a5df (patch)
tree743a26348e360c8b7f5eb89d4f704b015e902e68 /test/test_results.py
parentbc435e826dbe37969d9cbe280f58810d054932cc (diff)
New upstream version 1.12.3upstream/1.12.3
Diffstat (limited to 'test/test_results.py')
-rw-r--r--test/test_results.py13
1 files changed, 9 insertions, 4 deletions
diff --git a/test/test_results.py b/test/test_results.py
index 869ff83..e87b4b8 100644
--- a/test/test_results.py
+++ b/test/test_results.py
@@ -1,7 +1,7 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
-# Copyright 2015-2019 Mike Fährmann
+# Copyright 2015-2020 Mike Fährmann
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
@@ -21,12 +21,12 @@ TRAVIS_SKIP = {
"exhentai", "kissmanga", "mangafox", "dynastyscans", "nijie", "bobx",
"archivedmoe", "archiveofsins", "thebarchive", "fireden", "4plebs",
"sankaku", "idolcomplex", "mangahere", "readcomiconline", "mangadex",
- "sankakucomplex", "warosu", "fuskator",
+ "sankakucomplex", "warosu", "fuskator", "patreon",
}
# temporary issues, etc.
BROKEN = {
- "erolord",
+ "imxto",
"mangapark",
"photobucket",
}
@@ -109,7 +109,12 @@ class TestExtractorResults(unittest.TestCase):
self.assertEqual(result["url"], tjob.url_hash.hexdigest())
if "content" in result:
- self.assertEqual(result["content"], tjob.content_hash.hexdigest())
+ expected = result["content"]
+ digest = tjob.content_hash.hexdigest()
+ if isinstance(expected, str):
+ self.assertEqual(digest, expected, "content")
+ else: # assume iterable
+ self.assertIn(digest, expected, "content")
if "keyword" in result:
expected = result["keyword"]