aboutsummaryrefslogtreecommitdiff
path: root/test/world_wide_library.py
diff options
context:
space:
mode:
authorjahoti <jahoti@tilde.team>2021-09-04 00:00:00 +0000
committerjahoti <jahoti@tilde.team>2021-09-04 00:00:00 +0000
commit591c48a6903bbf324361610f81c628302cae7049 (patch)
tree174fee77253b147603966d2e6c40c5ffbb5e3e5a /test/world_wide_library.py
parent6c69435cef6a9cf5fc6bedfcf853d8ab10dc99ec (diff)
downloadbrowser-extension-591c48a6903bbf324361610f81c628302cae7049.tar.gz
browser-extension-591c48a6903bbf324361610f81c628302cae7049.zip
Make test suite mildly usable
Allow test/server.py to be run as a command and add some "webpages" for it.
Diffstat (limited to 'test/world_wide_library.py')
-rw-r--r--test/world_wide_library.py15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/world_wide_library.py b/test/world_wide_library.py
new file mode 100644
index 0000000..fc9e095
--- /dev/null
+++ b/test/world_wide_library.py
@@ -0,0 +1,15 @@
+# Copyright (C) 2021 jahoti <jahoti@tilde.team>
+# Licensing information is collated in the `copyright` file
+
+"""
+Our helpful little stand-in for the Internet
+"""
+
+catalog = {
+ 'http://gotmyowndoma.in': (302, {'location': 'http://gotmyowndoma.in/index.html'}, b''),
+ 'http://gotmyowndoma.in/': (302, {'location': 'http://gotmyowndoma.in/index.html'}, b''),
+ 'http://gotmyowndoma.in/index.html': (200, {}, 'data/pages/gotmyowndomain.html'),
+ 'https://gotmyowndoma.in': (302, {'location': 'https://gotmyowndoma.in/index.html'}, b''),
+ 'https://gotmyowndoma.in/': (302, {'location': 'https://gotmyowndoma.in/index.html'}, b''),
+ 'https://gotmyowndoma.in/index.html': (200, {}, 'data/pages/gotmyowndomain_https.html')
+}