Skip to content

Commit a364dda

Browse files
committed
tests: Temporarily skip breaking tests after update to podman-5.4.2
Signed-off-by: Monika Kairaityte <[email protected]>
1 parent d11de3d commit a364dda

File tree

12 files changed

+81
-0
lines changed

12 files changed

+81
-0
lines changed

tests/integration/deps/test_podman_compose_deps.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,20 @@
44

55
from tests.integration.test_utils import PodmanAwareRunSubprocessMixin
66
from tests.integration.test_utils import RunSubprocessMixin
7+
from tests.integration.test_utils import get_podman_version
78
from tests.integration.test_utils import is_systemd_available
89
from tests.integration.test_utils import podman_compose_path
910
from tests.integration.test_utils import test_path
1011

12+
SKIP_IF = get_podman_version() == get_podman_version().__class__("5.4.2")
13+
1114

1215
def compose_yaml_path(suffix: str = "") -> str:
1316
return os.path.join(os.path.join(test_path(), "deps"), f"docker-compose{suffix}.yaml")
1417

1518

1619
class TestComposeBaseDeps(unittest.TestCase, RunSubprocessMixin):
20+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
1721
def test_deps(self) -> None:
1822
try:
1923
output, _ = self.run_subprocess_assert_returncode([
@@ -89,6 +93,7 @@ def test_up_nodeps(self) -> None:
8993
"down",
9094
])
9195

96+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
9297
def test_podman_compose_run(self) -> None:
9398
"""
9499
This will test depends_on as well
@@ -143,6 +148,7 @@ def test_podman_compose_run(self) -> None:
143148

144149

145150
class TestComposeConditionalDeps(unittest.TestCase, RunSubprocessMixin):
151+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
146152
def test_deps_succeeds(self) -> None:
147153
suffix = "-conditional-succeeds"
148154
try:
@@ -191,6 +197,7 @@ class TestComposeConditionalDepsHealthy(unittest.TestCase, PodmanAwareRunSubproc
191197
def setUp(self) -> None:
192198
self.podman_version = self.retrieve_podman_version()
193199

200+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
194201
def test_up_deps_healthy(self) -> None:
195202
suffix = "-conditional-healthy"
196203
try:

tests/integration/in_pod/test_podman_compose_in_pod.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@
44
import unittest
55

66
from tests.integration.test_utils import RunSubprocessMixin
7+
from tests.integration.test_utils import get_podman_version
8+
9+
SKIP_IF = get_podman_version() == get_podman_version().__class__("5.4.2")
710

811

912
def base_path() -> str:
@@ -37,6 +40,7 @@ def failure_exitcode_when_rootful() -> int:
3740
# Test all combinations of command line argument in_pod and compose file argument in_pod.
3841
class TestPodmanComposeInPod(unittest.TestCase, RunSubprocessMixin):
3942
# compose file provides x-podman in_pod=false
43+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
4044
def test_x_podman_in_pod_false_command_line_in_pod_not_exists(self) -> None:
4145
"""
4246
Test that podman-compose will not create a pod, when x-podman in_pod=false and command line
@@ -115,6 +119,7 @@ def test_x_podman_in_pod_false_command_line_in_pod_true(self) -> None:
115119
# been created) and have expected_returncode=1 (see FIXME above)
116120
self.run_subprocess_assert_returncode(command_rm_pod)
117121

122+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
118123
def test_x_podman_in_pod_false_command_line_in_pod_false(self) -> None:
119124
"""
120125
Test that podman-compose will not create a pod as command line sets in_pod=False
@@ -160,6 +165,7 @@ def test_x_podman_in_pod_false_command_line_in_pod_false(self) -> None:
160165
# can not actually find this pod because it was not created
161166
self.run_subprocess_assert_returncode(command_rm_pod, 1)
162167

168+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
163169
def test_x_podman_in_pod_false_command_line_in_pod_empty_string(self) -> None:
164170
"""
165171
Test that podman-compose will not create a pod, when x-podman in_pod=false and command line
@@ -274,6 +280,7 @@ def test_x_podman_in_pod_true_command_line_in_pod_true(self) -> None:
274280
# been created) and have expected_returncode=1 (see FIXME above)
275281
self.run_subprocess_assert_returncode(command_rm_pod)
276282

283+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
277284
def test_x_podman_in_pod_true_command_line_in_pod_false(self) -> None:
278285
"""
279286
Test that podman-compose will not create a pod as command line sets in_pod=False
@@ -421,6 +428,7 @@ def test_x_podman_in_pod_not_exists_command_line_in_pod_true(self) -> None:
421428
# been created) and have expected_returncode=1 (see FIXME above)
422429
self.run_subprocess_assert_returncode(command_rm_pod)
423430

431+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
424432
def test_x_podman_in_pod_not_exists_command_line_in_pod_false(self) -> None:
425433
"""
426434
Test that podman-compose will not create a pod as command line sets in_pod=False
@@ -467,6 +475,7 @@ def test_x_podman_in_pod_not_exists_command_line_in_pod_false(self) -> None:
467475
# can not actually find this pod because it was not created
468476
self.run_subprocess_assert_returncode(command_rm_pod, 1)
469477

478+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
470479
def test_x_podman_in_pod_not_exists_command_line_in_pod_not_exists_docker_compat(self) -> None:
471480
"""
472481
Test that podman-compose will not create a pod when docker compat is requested.
@@ -518,6 +527,7 @@ def test_x_podman_in_pod_not_exists_command_line_in_pod_not_exists_docker_compat
518527
# can not actually find this pod because it was not created
519528
self.run_subprocess_assert_returncode(command_rm_pod, 1)
520529

530+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
521531
def test_x_podman_in_pod_not_exists_command_line_in_pod_not_exists_env_var(self) -> None:
522532
"""
523533
Test that podman-compose will not create a pod when env var is set.

tests/integration/include/test_podman_compose_include.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,13 @@
44
from pathlib import Path
55

66
from tests.integration.test_utils import RunSubprocessMixin
7+
from tests.integration.test_utils import get_podman_version
8+
9+
SKIP_IF = get_podman_version() == get_podman_version().__class__("5.4.2")
710

811

912
class TestPodmanComposeInclude(unittest.TestCase, RunSubprocessMixin):
13+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
1014
def test_podman_compose_include(self) -> None:
1115
"""
1216
Test that podman-compose can execute podman-compose -f <file> up with include

tests/integration/lifetime/test_lifetime.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,12 @@
88
from parameterized import parameterized
99

1010
from tests.integration.test_utils import RunSubprocessMixin
11+
from tests.integration.test_utils import get_podman_version
1112
from tests.integration.test_utils import podman_compose_path
1213
from tests.integration.test_utils import test_path
1314

15+
SKIP_IF = get_podman_version() == get_podman_version().__class__("5.4.2")
16+
1417

1518
class TestLifetime(unittest.TestCase, RunSubprocessMixin):
1619
def test_up_single_container(self) -> None:
@@ -69,6 +72,7 @@ def test_up_single_container(self) -> None:
6972
("no_ports", "up_single_container_many_times"),
7073
("with_ports", "up_single_container_many_times_with_ports"),
7174
])
75+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
7276
def test_up_single_container_many_times(self, name: str, subdir: str) -> None:
7377
"""Podman compose up should be able to start a container many times after it finishes
7478
running.

tests/integration/merge/reset_and_override_tags/override_tag_attribute/test_podman_compose_override_tag_attribute.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,12 @@
55
import unittest
66

77
from tests.integration.test_utils import RunSubprocessMixin
8+
from tests.integration.test_utils import get_podman_version
89
from tests.integration.test_utils import podman_compose_path
910
from tests.integration.test_utils import test_path
1011

12+
SKIP_IF = get_podman_version() == get_podman_version().__class__("5.4.2")
13+
1114

1215
def compose_yaml_path() -> str:
1316
return os.path.join(
@@ -18,6 +21,7 @@ def compose_yaml_path() -> str:
1821

1922
class TestComposeOverrideTagAttribute(unittest.TestCase, RunSubprocessMixin):
2023
# test if a service attribute from docker-compose.yaml file is overridden
24+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
2125
def test_override_tag_attribute(self) -> None:
2226
override_file = os.path.join(
2327
test_path(),

tests/integration/merge/reset_and_override_tags/override_tag_service/test_podman_compose_override_tag_service.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,12 @@
55
import unittest
66

77
from tests.integration.test_utils import RunSubprocessMixin
8+
from tests.integration.test_utils import get_podman_version
89
from tests.integration.test_utils import podman_compose_path
910
from tests.integration.test_utils import test_path
1011

12+
SKIP_IF = get_podman_version() == get_podman_version().__class__("5.4.2")
13+
1114

1215
def compose_yaml_path() -> str:
1316
return os.path.join(
@@ -18,6 +21,7 @@ def compose_yaml_path() -> str:
1821

1922
class TestComposeOverrideTagService(unittest.TestCase, RunSubprocessMixin):
2023
# test if whole service from docker-compose.yaml file is overridden in another file
24+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
2125
def test_override_tag_service(self) -> None:
2226
override_file = os.path.join(
2327
test_path(),

tests/integration/nets_test3/test_podman_compose_nets_test3.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,18 @@
66
from parameterized import parameterized
77

88
from tests.integration.test_utils import RunSubprocessMixin
9+
from tests.integration.test_utils import get_podman_version
910
from tests.integration.test_utils import podman_compose_path
1011
from tests.integration.test_utils import test_path
1112

13+
SKIP_IF = get_podman_version() == get_podman_version().__class__("5.4.2")
14+
1215

1316
def compose_yaml_path() -> str:
1417
return os.path.join(os.path.join(test_path(), "nets_test3"), "docker-compose.yml")
1518

1619

20+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
1721
class TestComposeNetsTest3(unittest.TestCase, RunSubprocessMixin):
1822
# test if services can access the networks of other services using their respective aliases
1923
@parameterized.expand([

tests/integration/network/test_podman_compose_network.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,12 @@
1212
from typing import Generator
1313

1414
from tests.integration.test_utils import RunSubprocessMixin
15+
from tests.integration.test_utils import get_podman_version
1516
from tests.integration.test_utils import podman_compose_path
1617
from tests.integration.test_utils import test_path
1718

19+
SKIP_IF = get_podman_version() == get_podman_version().__class__("5.4.2")
20+
1821

1922
class TestPodmanComposeNetwork(RunSubprocessMixin, unittest.TestCase):
2023
@staticmethod
@@ -41,6 +44,7 @@ def teardown(self) -> Generator[None, None, None]:
4144
]
4245
self.run_subprocess(down_cmd)
4346

47+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
4448
def test_networks(self) -> None:
4549
up_cmd = [
4650
"coverage",

tests/integration/network_scoped_aliases/test_podman_compose_network_scoped_aliases.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,20 @@
55
import unittest
66

77
from tests.integration.test_utils import RunSubprocessMixin
8+
from tests.integration.test_utils import get_podman_version
89
from tests.integration.test_utils import podman_compose_path
910
from tests.integration.test_utils import test_path
1011

12+
SKIP_IF = get_podman_version() == get_podman_version().__class__("5.4.2")
13+
1114

1215
class TestPodmanComposeNetworkScopedAliases(RunSubprocessMixin, unittest.TestCase):
1316
@staticmethod
1417
def compose_file() -> str:
1518
"""Returns the path to the compose file used for this test module"""
1619
return os.path.join(test_path(), "network_scoped_aliases", "docker-compose.yaml")
1720

21+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
1822
def test_network_scoped_aliases(self) -> None:
1923
try:
2024
self.up()

tests/integration/pod_args/test_podman_compose_pod_args.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@
55
import unittest
66

77
from tests.integration.test_utils import RunSubprocessMixin
8+
from tests.integration.test_utils import get_podman_version
9+
10+
SKIP_IF = get_podman_version() == get_podman_version().__class__("5.4.2")
811

912

1013
def base_path() -> str:
@@ -89,6 +92,7 @@ def test_x_podman_pod_args_unset_unset(self) -> None:
8992
["--infra=false", "--share="],
9093
)
9194

95+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
9296
def test_x_podman_pod_args_unset_empty(self) -> None:
9397
"""
9498
Test that podman-compose will use empty pod-args when unset in
@@ -100,6 +104,7 @@ def test_x_podman_pod_args_unset_empty(self) -> None:
100104
[],
101105
)
102106

107+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
103108
def test_x_podman_pod_args_unset_set(self) -> None:
104109
"""
105110
Test that podman-compose will use the passed pod-args when unset in
@@ -111,6 +116,7 @@ def test_x_podman_pod_args_unset_set(self) -> None:
111116
["--infra=false", "--share=", "--cpus=1"],
112117
)
113118

119+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
114120
def test_x_podman_pod_args_empty_unset(self) -> None:
115121
"""
116122
Test that podman-compose will use empty pod-args when set to an
@@ -122,6 +128,7 @@ def test_x_podman_pod_args_empty_unset(self) -> None:
122128
[],
123129
)
124130

131+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
125132
def test_x_podman_pod_args_empty_empty(self) -> None:
126133
"""
127134
Test that podman-compose will use empty pod-args when set to an
@@ -156,6 +163,7 @@ def test_x_podman_pod_args_set_unset(self) -> None:
156163
["--infra=false", "--share=", "--cpus=2"],
157164
)
158165

166+
@unittest.skipIf(SKIP_IF, "Breaks after updating podman to podman-5.4.2")
159167
def test_x_podman_pod_args_set_empty(self) -> None:
160168
"""
161169
Test that podman-compose will use empty pod-args when set to a

0 commit comments

Comments
 (0)