diff options
| author | Markus Heiser <markus.heiser@darmarIT.de> | 2025-07-29 16:31:28 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-07-29 16:31:28 +0200 |
| commit | 6b9e12e4c1b3c5012d8a4149093b84cff6fa4887 (patch) | |
| tree | c9adf3f4837f8943bf46a00091e2e37f3fa8b815 /tests | |
| parent | 40b78ad06c07a80ef636a19bbaf36574c0213b59 (diff) | |
[test] calculator plugin: report the DeprecationWarning once (#5070)
Reporting the DeprecationWarning once should be sufficient when running tests.
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/unit/test_plugin_calculator.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/unit/test_plugin_calculator.py b/tests/unit/test_plugin_calculator.py index 505812e19..ca5c5d6c8 100644 --- a/tests/unit/test_plugin_calculator.py +++ b/tests/unit/test_plugin_calculator.py @@ -1,6 +1,8 @@ # SPDX-License-Identifier: AGPL-3.0-or-later # pylint: disable=missing-module-docstring,disable=missing-class-docstring,invalid-name +import warnings + from parameterized.parameterized import parameterized import searx.plugins @@ -14,6 +16,10 @@ from .test_utils import random_string from .test_plugins import do_post_search +# Reporting the DeprecationWarning once should be sufficient when running tests +warnings.filterwarnings("once", category=DeprecationWarning) + + class PluginCalculator(SearxTestCase): def setUp(self): |