pytest-docker 3.2.2__tar.gz → 3.2.4__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_docker-3.2.2/src/pytest_docker.egg-info → pytest_docker-3.2.4}/PKG-INFO +2 -2
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/setup.cfg +3 -2
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/src/pytest_docker/plugin.py +4 -3
- {pytest_docker-3.2.2 → pytest_docker-3.2.4/src/pytest_docker.egg-info}/PKG-INFO +2 -2
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/src/pytest_docker.egg-info/requires.txt +1 -1
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/tests/test_dockercomposeexecutor.py +4 -4
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/LICENSE.txt +0 -0
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/README.md +0 -0
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/pyproject.toml +0 -0
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/setup.py +0 -0
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/src/pytest_docker/__init__.py +0 -0
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/src/pytest_docker/py.typed +0 -0
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/src/pytest_docker.egg-info/SOURCES.txt +0 -0
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/src/pytest_docker.egg-info/dependency_links.txt +0 -0
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/src/pytest_docker.egg-info/entry_points.txt +0 -0
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/src/pytest_docker.egg-info/top_level.txt +0 -0
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/tests/test_docker_ip.py +0 -0
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/tests/test_docker_services.py +0 -0
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/tests/test_fixtures.py +0 -0
- {pytest_docker-3.2.2 → pytest_docker-3.2.4}/tests/test_integration.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pytest-docker
|
|
3
|
-
Version: 3.2.
|
|
3
|
+
Version: 3.2.4
|
|
4
4
|
Summary: Simple pytest fixtures for Docker and Docker Compose based tests
|
|
5
5
|
Home-page: https://github.com/avast/pytest-docker
|
|
6
6
|
Author: Max K., Andre Caron
|
|
@@ -23,7 +23,7 @@ Classifier: Operating System :: Microsoft :: Windows
|
|
|
23
23
|
Requires-Python: >=3.8
|
|
24
24
|
Description-Content-Type: text/markdown
|
|
25
25
|
License-File: LICENSE.txt
|
|
26
|
-
Requires-Dist: pytest<
|
|
26
|
+
Requires-Dist: pytest<10.0,>=4.0
|
|
27
27
|
Requires-Dist: attrs>=19.2.0
|
|
28
28
|
Provides-Extra: docker-compose-v1
|
|
29
29
|
Requires-Dist: docker-compose<2.0,>=1.27.3; extra == "docker-compose-v1"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[metadata]
|
|
2
2
|
name = pytest-docker
|
|
3
|
-
version = 3.2.
|
|
3
|
+
version = 3.2.4
|
|
4
4
|
description = Simple pytest fixtures for Docker and Docker Compose based tests
|
|
5
5
|
long_description = file: README.md
|
|
6
6
|
long_description_content_type = text/markdown
|
|
@@ -30,7 +30,7 @@ package_dir =
|
|
|
30
30
|
=src
|
|
31
31
|
packages = pytest_docker
|
|
32
32
|
install_requires =
|
|
33
|
-
pytest >=4.0, <
|
|
33
|
+
pytest >=4.0, <10.0
|
|
34
34
|
attrs >=19.2.0
|
|
35
35
|
|
|
36
36
|
[options.extras_require]
|
|
@@ -79,6 +79,7 @@ strict = true
|
|
|
79
79
|
mypy_path = "src/pytest_docker,tests"
|
|
80
80
|
namespace_packages = true
|
|
81
81
|
warn_unused_ignores = true
|
|
82
|
+
warn_return_any = false
|
|
82
83
|
|
|
83
84
|
[egg_info]
|
|
84
85
|
tag_build =
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import contextlib
|
|
2
2
|
import os
|
|
3
|
+
from pathlib import Path
|
|
3
4
|
import re
|
|
4
5
|
import subprocess
|
|
5
6
|
import time
|
|
6
7
|
import timeit
|
|
7
|
-
from typing import Any, Dict, Iterable, Iterator, List, Tuple, Union
|
|
8
|
+
from typing import Any, Dict, Iterable, Iterator, List, Optional, Tuple, Union
|
|
8
9
|
|
|
9
10
|
import attr
|
|
10
11
|
import pytest
|
|
@@ -78,7 +79,7 @@ class Services:
|
|
|
78
79
|
"""
|
|
79
80
|
|
|
80
81
|
# Lookup in the cache.
|
|
81
|
-
cache: int = self._services.get(service, {}).get(container_port, None)
|
|
82
|
+
cache: Optional[int] = self._services.get(service, {}).get(container_port, None)
|
|
82
83
|
if cache is not None:
|
|
83
84
|
return cache
|
|
84
85
|
|
|
@@ -119,7 +120,7 @@ class Services:
|
|
|
119
120
|
raise Exception("Timeout reached while waiting on service!")
|
|
120
121
|
|
|
121
122
|
|
|
122
|
-
def str_to_list(arg: Union[str, List[Any], Tuple[Any]]) -> Union[List[Any], Tuple[Any]]:
|
|
123
|
+
def str_to_list(arg: Union[str, Path, List[Any], Tuple[Any]]) -> Union[List[Any], Tuple[Any]]:
|
|
123
124
|
if isinstance(arg, (list, tuple)):
|
|
124
125
|
return arg
|
|
125
126
|
return [arg]
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pytest-docker
|
|
3
|
-
Version: 3.2.
|
|
3
|
+
Version: 3.2.4
|
|
4
4
|
Summary: Simple pytest fixtures for Docker and Docker Compose based tests
|
|
5
5
|
Home-page: https://github.com/avast/pytest-docker
|
|
6
6
|
Author: Max K., Andre Caron
|
|
@@ -23,7 +23,7 @@ Classifier: Operating System :: Microsoft :: Windows
|
|
|
23
23
|
Requires-Python: >=3.8
|
|
24
24
|
Description-Content-Type: text/markdown
|
|
25
25
|
License-File: LICENSE.txt
|
|
26
|
-
Requires-Dist: pytest<
|
|
26
|
+
Requires-Dist: pytest<10.0,>=4.0
|
|
27
27
|
Requires-Dist: attrs>=19.2.0
|
|
28
28
|
Provides-Extra: docker-compose-v1
|
|
29
29
|
Requires-Dist: docker-compose<2.0,>=1.27.3; extra == "docker-compose-v1"
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import subprocess
|
|
2
2
|
from unittest import mock
|
|
3
3
|
|
|
4
|
-
import
|
|
4
|
+
from pathlib import Path
|
|
5
5
|
from pytest_docker.plugin import DockerComposeExecutor
|
|
6
6
|
|
|
7
7
|
|
|
@@ -31,9 +31,9 @@ def test_execute_docker_compose_v2() -> None:
|
|
|
31
31
|
]
|
|
32
32
|
|
|
33
33
|
|
|
34
|
-
def
|
|
35
|
-
compose_file:
|
|
36
|
-
docker_compose = DockerComposeExecutor("docker compose", compose_file, "pytest123")
|
|
34
|
+
def test_path_compose_file() -> None:
|
|
35
|
+
compose_file: Path = Path("/tmp/docker-compose.yml")
|
|
36
|
+
docker_compose = DockerComposeExecutor("docker compose", compose_file, "pytest123")
|
|
37
37
|
with mock.patch("subprocess.check_output") as check_output:
|
|
38
38
|
docker_compose.execute("up")
|
|
39
39
|
assert check_output.call_args_list == [
|
|
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
|