mirror of
https://github.com/searxng/searxng
synced 2024-01-01 19:24:07 +01:00
Fix: The environment variable SEARX_SETTINGS_PATH was ignored
Refactor searx.settings_loader.py.get_user_settings_path (SearxSettingsException is never raised)
This commit is contained in:
parent
56000d5162
commit
7635e5403e
2 changed files with 42 additions and 19 deletions
|
|
@ -23,10 +23,10 @@ class TestLoad(SearxTestCase):
|
|||
settings_loader.load_yaml(join(test_dir, '/settings/empty_settings.yml'))
|
||||
|
||||
def test_check_settings_yml(self):
|
||||
self.assertIsNone(settings_loader.check_settings_yml('/dev/zero'))
|
||||
self.assertIsNone(settings_loader.existing_filename_or_none('/dev/zero'))
|
||||
|
||||
bad_settings_path = join(test_dir, 'settings/syntaxerror_settings.yml')
|
||||
self.assertEqual(settings_loader.check_settings_yml(bad_settings_path), bad_settings_path)
|
||||
self.assertEqual(settings_loader.existing_filename_or_none(bad_settings_path), bad_settings_path)
|
||||
|
||||
|
||||
class TestDefaultSettings(SearxTestCase):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue