summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorAlexandre Flament <alex@al-f.net>2020-10-03 15:02:44 +0200
committerAlexandre FLAMENT <alexandre.flament@hesge.ch>2022-03-05 10:50:48 +0000
commit1c7d8815fb54dd37ed6765560c223cb93976b6f4 (patch)
tree14cdc2f8f9f7988d0026a92eab9098774db5b578 /tests
parent927aa71133839ce5713b742b43285953301adf36 (diff)
[mod] URL for the static file contains the sha1
* allow to cache the static file forever * avoid bugs when the static files are updated but not reloaded
Diffstat (limited to 'tests')
-rw-r--r--tests/unit/test_webapp.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/unit/test_webapp.py b/tests/unit/test_webapp.py
index aed6f2dd..872b8d01 100644
--- a/tests/unit/test_webapp.py
+++ b/tests/unit/test_webapp.py
@@ -23,6 +23,11 @@ class ViewsTestCase(SearxTestCase):
webapp.app.config['TESTING'] = True # to get better error messages
self.app = webapp.app.test_client()
+ # remove sha for the static file
+ # so the tests don't have to care about the changing URLs
+ for k in webapp.static_files:
+ webapp.static_files[k] = None
+
# set some defaults
test_results = [
{