aboutsummaryrefslogtreecommitdiffstats
path: root/python/tests
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@archive.org>2020-01-09 12:34:14 -0800
committerBryan Newbold <bnewbold@archive.org>2020-01-09 16:32:51 -0800
commit101e3c818fa5852c11003e616526726e189ab2c3 (patch)
tree3d41ab201bad9a560dbe206171b3915833b28a9a /python/tests
parent55ef20102eaf8123dfc41e1d7ae80c50607c99f4 (diff)
downloadsandcrawler-101e3c818fa5852c11003e616526726e189ab2c3.tar.gz
sandcrawler-101e3c818fa5852c11003e616526726e189ab2c3.zip
location comes as a string, not list
Diffstat (limited to 'python/tests')
-rw-r--r--python/tests/test_wayback.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/python/tests/test_wayback.py b/python/tests/test_wayback.py
index 2aafe7c..efffbe2 100644
--- a/python/tests/test_wayback.py
+++ b/python/tests/test_wayback.py
@@ -118,8 +118,8 @@ def wayback_client(cdx_client, mocker):
client.rstore = mocker.Mock()
resource = mocker.Mock()
client.rstore.load_resource = mocker.MagicMock(return_value=resource)
- resource.get_status = mocker.MagicMock(return_value=[200])
- resource.get_location = mocker.MagicMock(return_value=[WARC_TARGET])
+ resource.get_status = mocker.MagicMock(return_value=(200, "Ok"))
+ resource.get_location = mocker.MagicMock(return_value=WARC_TARGET)
body = mocker.Mock()
resource.open_raw_content = mocker.MagicMock(return_value=body)
body.read = mocker.MagicMock(return_value=WARC_BODY)
@@ -140,8 +140,8 @@ def wayback_client_pdf(cdx_client, mocker):
client.rstore = mocker.Mock()
resource = mocker.Mock()
client.rstore.load_resource = mocker.MagicMock(return_value=resource)
- resource.get_status = mocker.MagicMock(return_value=[200])
- resource.get_location = mocker.MagicMock(return_value=[WARC_TARGET])
+ resource.get_status = mocker.MagicMock(return_value=(200, "Ok"))
+ resource.get_location = mocker.MagicMock(return_value=WARC_TARGET)
body = mocker.Mock()
resource.open_raw_content = mocker.MagicMock(return_value=body)
body.read = mocker.MagicMock(return_value=pdf_bytes)