summaryrefslogtreecommitdiff
path: root/crocoite/test_tools.py
diff options
context:
space:
mode:
authorLars-Dominik Braun <lars@6xq.net>2019-07-02 09:14:55 +0200
committerLars-Dominik Braun <lars@6xq.net>2019-07-02 09:16:55 +0200
commit9ff793e96139ed40090ab9d8c3cae99b284858e5 (patch)
treee1b568fc77c0600a767fea1f541de1d5e85d87a5 /crocoite/test_tools.py
parent9d8d48358bf44d7a3e4918bcdac3f4ef1348541b (diff)
downloadcrocoite-9ff793e96139ed40090ab9d8c3cae99b284858e5.tar.gz
crocoite-9ff793e96139ed40090ab9d8c3cae99b284858e5.tar.bz2
crocoite-9ff793e96139ed40090ab9d8c3cae99b284858e5.zip
Stabilize WARC headers
In preparation for 1.0 release: - Correct mime types - Add X-Crocoite-Type, so logs, scripts, dom-snapshots and screenshots can be identified easily - Remove random WARC headers like X-Chrome-Initiator. We don’t want to maintain those. - Remove non-standard urn-based package URLs. Can’t use them without a urn-registration
Diffstat (limited to 'crocoite/test_tools.py')
-rw-r--r--crocoite/test_tools.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/crocoite/test_tools.py b/crocoite/test_tools.py
index 106aa59..e8edb98 100644
--- a/crocoite/test_tools.py
+++ b/crocoite/test_tools.py
@@ -28,7 +28,6 @@ from warcio.statusandheaders import StatusAndHeaders
from pkg_resources import parse_version
from .tools import mergeWarc, Errata, FixableErrata
-from .util import packageUrl
@pytest.fixture
def writer():
@@ -49,7 +48,9 @@ def recordsEqual(golden, underTest):
def makeGolden(writer, records):
# additional warcinfo is written. Content does not matter.
- record = writer.create_warc_record (packageUrl ('warcinfo'), 'warcinfo',
+ record = writer.create_warc_record (
+ '',
+ 'warcinfo',
payload=b'',
warc_headers_dict={'Content-Type': 'text/plain; encoding=utf-8'})
records.insert (0, record)