aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorGertjan van den Burg <gertjanvandenburg@gmail.com>2020-09-25 23:46:34 +0200
committerGertjan van den Burg <gertjanvandenburg@gmail.com>2020-09-25 23:46:34 +0200
commitb236ff1bc09bfc6dc8ef6688f39e0ac4d699bad9 (patch)
treea67f43a9178401fbdc0d6e6b7cb7047250ab841c /tests
parentMerge branch 'bugfix/neurips' into master (diff)
parentImprove docs (diff)
downloadpaper2remarkable-b236ff1bc09bfc6dc8ef6688f39e0ac4d699bad9.tar.gz
paper2remarkable-b236ff1bc09bfc6dc8ef6688f39e0ac4d699bad9.zip
Merge branch 'bugfix/html-figure' into master
Diffstat (limited to 'tests')
-rw-r--r--tests/test_providers.py13
1 files changed, 12 insertions, 1 deletions
diff --git a/tests/test_providers.py b/tests/test_providers.py
index eeaef82..70d012a 100644
--- a/tests/test_providers.py
+++ b/tests/test_providers.py
@@ -278,7 +278,10 @@ class TestProviders(unittest.TestCase):
def test_html_3(self):
prov = HTML(upload=False, verbose=VERBOSE)
url = "https://conclave-team.github.io/conclave-site/"
- exp = "Conclave_Case_Study_-_A_Private_and_Secure_Real-Time_Collaborative_Text_Editor.pdf"
+ #exp = "Conclave_Case_Study_-_A_Private_and_Secure_Real-Time_Collaborative_Text_Editor.pdf"
+ # NOTE: Title differs between Readability.JS and readability-lxml, we
+ # assume that testing is done with Readability.JS
+ exp = "Conclave.pdf"
filename = prov.run(url)
self.assertEqual(exp, os.path.basename(filename))
# this is a proxy test to check that all images are included
@@ -291,6 +294,13 @@ class TestProviders(unittest.TestCase):
# this is a proxy test to check that all images are included
self.assertEqual(4, len(pdfplumber.open(filename).pages))
+ def test_html_5(self):
+ prov = HTML(upload=False, verbose=VERBOSE)
+ url = "https://www.spiegel.de/panorama/london-tausende-rechtsextreme-demonstranten-wollen-statuen-schuetzen-a-2a1ed9b9-708a-40dc-a5ff-f312e97a60ca#"
+ filename = prov.run(url)
+ # this is a proxy test to check that all images are included
+ self.assertEqual(4, len(pdfplumber.open(filename).pages))
+
def test_semantic_scholar_1(self):
prov = SemanticScholar(upload=False, verbose=VERBOSE)
url = "https://pdfs.semanticscholar.org/1b01/dea77e9cbf049b4ee8b68dc4d43529d06299.pdf"
@@ -320,5 +330,6 @@ class TestProviders(unittest.TestCase):
self.assertEqual(exp, os.path.basename(filename))
+
if __name__ == "__main__":
unittest.main()