diff --git a/ci-scripts/tests/deployment.py b/ci-scripts/tests/deployment.py index 47e459d6a4..45bffe9a0a 100644 --- a/ci-scripts/tests/deployment.py +++ b/ci-scripts/tests/deployment.py @@ -65,6 +65,15 @@ class TestDeploymentMethods(unittest.TestCase): self.assertFalse(deploy) self.cont.yamlPath = old + def test_deployfails_2svc(self): + # fails reliably + old = self.cont.yamlPath + self.cont.yamlPath[0] = 'tests/simple-fail-2svc/' + deploy = self.cont.DeployObject(self.html) + self.cont.UndeployObject(self.html, self.ran) + self.assertFalse(deploy) + self.cont.yamlPath = old + def test_deploy_ran(self): self.cont.yamlPath[0] = 'yaml_files/5g_rfsimulator_tdd_dora' self.cont.services[0] = "oai-gnb" diff --git a/ci-scripts/tests/simple-fail-2svc/docker-compose.yml b/ci-scripts/tests/simple-fail-2svc/docker-compose.yml new file mode 100644 index 0000000000..8b30c4aa08 --- /dev/null +++ b/ci-scripts/tests/simple-fail-2svc/docker-compose.yml @@ -0,0 +1,23 @@ +services: + test1: + image: ubuntu:jammy + container_name: test_container1 + cap_drop: + - ALL + entrypoint: /bin/bash -c "false" + healthcheck: + test: /bin/bash -c "true" + interval: 1s + timeout: 1s + retries: 1 + test2: + image: ubuntu:jammy + container_name: test_container2 + cap_drop: + - ALL + entrypoint: /bin/bash -c "sleep infinity" + healthcheck: + test: /bin/bash -c "true" + interval: 1s + timeout: 1s + retries: 1