summaryrefslogtreecommitdiffstats
path: root/tests/lsp_tests/conftest.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/lsp_tests/conftest.py')
-rw-r--r--tests/lsp_tests/conftest.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/tests/lsp_tests/conftest.py b/tests/lsp_tests/conftest.py
index 8b42582..2aff4a2 100644
--- a/tests/lsp_tests/conftest.py
+++ b/tests/lsp_tests/conftest.py
@@ -1,5 +1,7 @@
import pytest
+
from debputy.plugin.api.feature_set import PluginProvidedFeatureSet
+from debputy.util import setup_logging
try:
from pygls.server import LanguageServer
@@ -22,8 +24,16 @@ except ImportError:
HAS_PYGLS = False
+@pytest.fixture(scope="session")
+def enable_logging() -> None:
+ setup_logging(log_only_to_stderr=True, reconfigure_logging=True)
+
+
@pytest.fixture()
-def ls(debputy_plugin_feature_set: PluginProvidedFeatureSet) -> "LanguageServer":
+def ls(
+ enable_logging,
+ debputy_plugin_feature_set: PluginProvidedFeatureSet,
+) -> "LanguageServer":
if not HAS_PYGLS:
pytest.skip("Missing pygls")
ls = LanguageServer("debputy", "v<test>")