pytest_httpserver 1.1.2__tar.gz → 1.1.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/CHANGES.rst +14 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/PKG-INFO +1 -1
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/doc/conf.py +1 -1
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/pyproject.toml +3 -3
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/pytest_httpserver/httpserver.py +2 -1
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_release.py +1 -0
- pytest_httpserver-1.1.3/tests/test_thread_type.py +21 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/CONTRIBUTION.md +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/LICENSE +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/README.md +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/doc/Makefile +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/doc/_static/.placeholder +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/doc/api.rst +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/doc/background.rst +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/doc/changes.rst +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/doc/fixtures.rst +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/doc/guide.rst +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/doc/howto.rst +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/doc/index.rst +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/doc/patch.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/doc/tutorial.rst +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/doc/upgrade.rst +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/example.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/example_pytest.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/pytest_httpserver/__init__.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/pytest_httpserver/blocking_httpserver.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/pytest_httpserver/hooks.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/pytest_httpserver/py.typed +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/pytest_httpserver/pytest_plugin.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/assets/Makefile +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/assets/README +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/assets/rootCA.cnf +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/assets/rootCA.crt +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/assets/rootCA.key +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/assets/rootCA.srl +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/assets/server.cnf +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/assets/server.crt +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/assets/server.csr +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/assets/server.key +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/assets/v3.ext +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/conftest.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_example_blocking_httpserver.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_example_query_params1.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_example_query_params2.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_authorization_headers.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_case_insensitive_matcher.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_check.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_check_handler_errors.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_custom_handler.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_custom_hooks.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_custom_request_matcher.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_header_value_matcher.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_hooks.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_json_matcher.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_log_querying.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_query_params_dict.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_query_params_never_do_this.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_query_params_proper_use.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_regexp.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_timeout_requests.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_url_matcher.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_wait_success.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_blocking_httpserver.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_handler_errors.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_headers.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_hooks.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_ip_protocols.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_json_matcher.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_log_leak.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_log_querying.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_matcher.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_mixed.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_oneshot.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_ordered.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_parse_qs.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_permanent.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_port_changing.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_querymatcher.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_querystring.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_ssl.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_threaded.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_urimatch.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_wait.py +0 -0
- {pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/test_with_statement.py +0 -0
|
@@ -2,6 +2,20 @@
|
|
|
2
2
|
Release Notes
|
|
3
3
|
=============
|
|
4
4
|
|
|
5
|
+
.. _Release Notes_1.1.3:
|
|
6
|
+
|
|
7
|
+
1.1.3
|
|
8
|
+
=====
|
|
9
|
+
|
|
10
|
+
.. _Release Notes_1.1.3_Bug Fixes:
|
|
11
|
+
|
|
12
|
+
Bug Fixes
|
|
13
|
+
---------
|
|
14
|
+
|
|
15
|
+
- Run server threads with daemon flag, preventing shutdown issues.
|
|
16
|
+
`#411 <https://github.com/csernazs/pytest-httpserver/pull/411>`_
|
|
17
|
+
|
|
18
|
+
|
|
5
19
|
.. _Release Notes_1.1.2:
|
|
6
20
|
|
|
7
21
|
1.1.2
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[tool.poetry]
|
|
2
2
|
name = "pytest_httpserver"
|
|
3
|
-
version = "1.1.
|
|
3
|
+
version = "1.1.3"
|
|
4
4
|
description = "pytest-httpserver is a httpserver for pytest"
|
|
5
5
|
authors = ["Zsolt Cserna <cserna.zsolt@gmail.com>"]
|
|
6
6
|
license = "MIT"
|
|
@@ -38,14 +38,14 @@ pytest_httpserver = "pytest_httpserver.pytest_plugin"
|
|
|
38
38
|
optional = true
|
|
39
39
|
|
|
40
40
|
[tool.poetry.group.develop.dependencies]
|
|
41
|
-
pre-commit = ">=2.20,<
|
|
41
|
+
pre-commit = ">=2.20,<5.0"
|
|
42
42
|
requests = "*"
|
|
43
43
|
Sphinx = ">=5.1.1,<8.0.0"
|
|
44
44
|
sphinx-rtd-theme = ">=1,<4"
|
|
45
45
|
reno = "*"
|
|
46
46
|
types-requests = "*"
|
|
47
47
|
pytest = ">=7.1.3,<9.0.0"
|
|
48
|
-
pytest-cov = ">=3,<
|
|
48
|
+
pytest-cov = ">=3,<7"
|
|
49
49
|
coverage = ">=6.4.4,<8.0.0"
|
|
50
50
|
tomli = { version = "*", markers = "python_version < '3.11'"}
|
|
51
51
|
black = "*"
|
|
@@ -770,7 +770,8 @@ class HTTPServerBase(abc.ABC): # pylint: disable=too-many-instance-attributes
|
|
|
770
770
|
)
|
|
771
771
|
|
|
772
772
|
self.port = self.server.port # Update port (needed if `port` was set to 0)
|
|
773
|
-
|
|
773
|
+
# Explicitly make the new thread daemonic to avoid shutdown issues
|
|
774
|
+
self.server_thread = threading.Thread(target=self.thread_target, daemon=True)
|
|
774
775
|
self.server_thread.start()
|
|
775
776
|
|
|
776
777
|
def stop(self):
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
import threading
|
|
4
|
+
from typing import TYPE_CHECKING
|
|
5
|
+
|
|
6
|
+
import requests
|
|
7
|
+
from werkzeug import Response
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
from werkzeug import Request
|
|
11
|
+
|
|
12
|
+
from pytest_httpserver import HTTPServer
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
def test_server_thread_is_daemon(httpserver: HTTPServer):
|
|
16
|
+
def handler(_request: Request):
|
|
17
|
+
return Response(f"{threading.current_thread().daemon}")
|
|
18
|
+
|
|
19
|
+
httpserver.expect_request("/foo").respond_with_handler(handler)
|
|
20
|
+
|
|
21
|
+
assert requests.get(httpserver.url_for("/foo")).text == "True"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/pytest_httpserver/blocking_httpserver.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_example_query_params1.py
RENAMED
|
File without changes
|
{pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_example_query_params2.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_custom_handler.py
RENAMED
|
File without changes
|
{pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_custom_hooks.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_json_matcher.py
RENAMED
|
File without changes
|
{pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_log_querying.py
RENAMED
|
File without changes
|
{pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_query_params_dict.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_timeout_requests.py
RENAMED
|
File without changes
|
{pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_url_matcher.py
RENAMED
|
File without changes
|
{pytest_httpserver-1.1.2 → pytest_httpserver-1.1.3}/tests/examples/test_howto_wait_success.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|