mirror of
https://github.com/searxng/searxng.git
synced 2025-09-03 08:48:35 +02:00
[fix] unit tests: fix load / unload engines & fix messages
- https://github.com/searxng/searxng/pull/3746#issuecomment-2300965005 - https://github.com/searxng/searxng/issues/2988#issuecomment-2226929084 Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
This commit is contained in:
parent
5c6b126d7f
commit
5be55e3309
3 changed files with 13 additions and 0 deletions
|
@ -2,6 +2,7 @@
|
|||
# pylint: disable=missing-module-docstring, invalid-name
|
||||
|
||||
from copy import copy
|
||||
import logging
|
||||
|
||||
import searx.search
|
||||
from searx.search import SearchQuery, EngineRef
|
||||
|
@ -46,8 +47,13 @@ class SearchQueryTestCase(SearxTestCase): # pylint: disable=missing-class-docst
|
|||
class SearchTestCase(SearxTestCase): # pylint: disable=missing-class-docstring
|
||||
def setUp(self):
|
||||
|
||||
log = logging.getLogger("searx")
|
||||
log_lev = log.level
|
||||
log.setLevel(logging.ERROR)
|
||||
from searx import webapp # pylint: disable=import-outside-toplevel
|
||||
|
||||
log.setLevel(log_lev)
|
||||
|
||||
self.app = webapp.app
|
||||
|
||||
@classmethod
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue