diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index a591618..4abcc29 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,6 @@ repos: - repo: https://github.com/psf/black-pre-commit-mirror - rev: 25.12.0 + rev: 26.1.0 hooks: - id: black args: [--safe, --quiet] diff --git a/tests/test_http.py b/tests/test_http.py index 11902fd..b603eb0 100644 --- a/tests/test_http.py +++ b/tests/test_http.py @@ -10,7 +10,6 @@ from pytest_localserver import http from pytest_localserver import plugin - # define test fixture here again in order to run tests without having to # install the plugin anew every single time httpserver = plugin.httpserver @@ -304,17 +303,13 @@ def test_httpserver_init_failure_no_stderr_during_cleanup(tmp_path): script_path = tmp_path.joinpath("script.py") - script_path.write_text( - textwrap.dedent( - """ + script_path.write_text(textwrap.dedent(""" from pytest_localserver import http from unittest.mock import patch with patch("pytest_localserver.http.make_server", side_effect=RuntimeError("init failure")): server = http.ContentServer() - """ - ) - ) + """)) result = subprocess.run([sys.executable, str(script_path)], stderr=subprocess.PIPE) diff --git a/tests/test_https.py b/tests/test_https.py index d66450b..4647441 100644 --- a/tests/test_https.py +++ b/tests/test_https.py @@ -4,7 +4,6 @@ from pytest_localserver import https from pytest_localserver import plugin - # define test fixture here again in order to run tests without having to # install the plugin anew every single time httpsserver = plugin.httpsserver diff --git a/tests/test_smtp.py b/tests/test_smtp.py index 7fc3882..77e2f6e 100644 --- a/tests/test_smtp.py +++ b/tests/test_smtp.py @@ -9,7 +9,6 @@ from pytest_localserver import plugin - smtp = pytest.importorskip("pytest_localserver.smtp")