mirror of
https://github.com/containers/podman-compose.git
synced 2025-08-09 21:57:44 +02:00
Run should not add --requires if --no-deps.
Fixes #717. Signed-off-by: Emanuel Rietveld <e.j.rietveld@gmail.com>
This commit is contained in:
@ -35,6 +35,31 @@ class TestComposeBaseDeps(unittest.TestCase, RunSubprocessMixin):
|
||||
"down",
|
||||
])
|
||||
|
||||
def test_run_nodeps(self):
|
||||
try:
|
||||
output, error = self.run_subprocess_assert_returncode([
|
||||
podman_compose_path(),
|
||||
"-f",
|
||||
compose_yaml_path(),
|
||||
"run",
|
||||
"--rm",
|
||||
"--no-deps",
|
||||
"sleep",
|
||||
"/bin/sh",
|
||||
"-c",
|
||||
"wget -O - http://web:8000/hosts || echo Failed to connect",
|
||||
])
|
||||
self.assertNotIn(b"HTTP request sent, awaiting response... 200 OK", output)
|
||||
self.assertNotIn(b"deps_web_1", output)
|
||||
self.assertIn(b"Failed to connect", output)
|
||||
finally:
|
||||
self.run_subprocess_assert_returncode([
|
||||
podman_compose_path(),
|
||||
"-f",
|
||||
compose_yaml_path(),
|
||||
"down",
|
||||
])
|
||||
|
||||
|
||||
class TestComposeConditionalDeps(unittest.TestCase, RunSubprocessMixin):
|
||||
def test_deps_succeeds(self):
|
||||
|
Reference in New Issue
Block a user