summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorMarkus Heiser <markus.heiser@darmarit.de>2021-01-26 11:46:36 +0100
committerMarkus Heiser <markus.heiser@darmarit.de>2021-01-26 11:46:36 +0100
commit923b490022ae51745d24efd9aa0f699836a516ee (patch)
treee3265e01ad06ccfe4a6faa39142a5462444f0f5d /Makefile
parentff6804e5451651c11dd8480dad710632725ff4d6 (diff)
downloadsearxng-923b490022ae51745d24efd9aa0f699836a516ee.tar.gz
searxng-923b490022ae51745d24efd9aa0f699836a516ee.zip
[mod] add Makfile targets for search.checker.<engine_name>
To check all engines: make search.checker To check a engine 'google news' replace space by underline: make search.checker.google_news To see HTTP requests and more use SEARX_DEBUG: make SEARX_DEBUG=1 search.checker.google_news To filter out HTTP redirects: make SEARX_DEBUG=1 search.checker.google_news | grep -A1 "HTTP/1.1\" 3[0-9][0-9]" ... Engine google news Checking https://news.google.com:443 "GET /search?q=life&hl=en&lr=lang_en&ie=utf8&oe=utf8&ceid=US%3Aen&gl=US HTTP/1.1" 302 0 https://news.google.com:443 "GET /search?q=life&hl=en-US&lr=lang_en&ie=utf8&oe=utf8&ceid=US:en&gl=US HTTP/1.1" 200 None -- https://news.google.com:443 "GET /search?q=computer&hl=en&lr=lang_en&ie=utf8&oe=utf8&ceid=US%3Aen&gl=US HTTP/1.1" 302 0 https://news.google.com:443 "GET /search?q=computer&hl=en-US&lr=lang_en&ie=utf8&oe=utf8&ceid=US:en&gl=US HTTP/1.1" 200 None -- Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile15
1 files changed, 14 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 55b744786..c52e93cdb 100644
--- a/Makefile
+++ b/Makefile
@@ -166,6 +166,18 @@ PHONY += gecko.driver
gecko.driver:
$(PY_ENV_ACT); ./manage.sh install_geckodriver
+# search.checker
+# --------------
+
+search.checker: pyenvinstall
+ $(Q)$(PY_ENV_ACT); searx-checker -v
+
+ENGINE_TARGETS=$(patsubst searx/engines/%.py,search.checker.%,$(wildcard searx/engines/[!_]*.py))
+
+$(ENGINE_TARGETS): pyenvinstall
+ $(Q)$(PY_ENV_ACT); searx-checker -v "$(subst _, ,$(patsubst search.checker.%,%,$@))"
+
+
# test
# ----
@@ -180,7 +192,8 @@ PYLINT_FILES=\
searx/engines/digg.py \
searx/engines/google.py \
searx/engines/google_news.py \
- searx/engines/google_videos.py
+ searx/engines/google_videos.py \
+ searx/engines/google_images.py
test.pylint: pyenvinstall
$(call cmd,pylint,$(PYLINT_FILES))