diff --git a/tests/integration/targets/connection_docker/aliases b/tests/integration/targets/connection_docker/aliases index 02b78723..8beddaed 100644 --- a/tests/integration/targets/connection_docker/aliases +++ b/tests/integration/targets/connection_docker/aliases @@ -1,2 +1,3 @@ shippable/posix/group4 +skip/docker # coverage does not work if we're inside a docker container, since we cannot access this container's /tmp dir from the new container destructive diff --git a/tests/integration/targets/connection_docker/runme.sh b/tests/integration/targets/connection_docker/runme.sh index d39df505..d328697a 100755 --- a/tests/integration/targets/connection_docker/runme.sh +++ b/tests/integration/targets/connection_docker/runme.sh @@ -37,8 +37,12 @@ trap cleanup INT TERM EXIT echo "Start containers" for CONTAINER in ${DOCKER_CONTAINERS}; do - docker run --rm --name ${CONTAINER} --detach ${IMAGE} /bin/sh -c 'sleep 10m' - docker exec ${CONTAINER} pip3 install coverage + if [ "${ANSIBLE_TEST_COVERAGE}" == "" ]; then + docker run --rm --name ${CONTAINER} --detach ${IMAGE} /bin/sh -c 'sleep 10m' + else + docker run --rm --name ${CONTAINER} --detach -v /tmp:/tmp ${IMAGE} /bin/sh -c 'sleep 10m' + docker exec ${CONTAINER} pip3 install coverage + fi echo ${CONTAINER} done