|
|
@ -17,6 +17,8 @@ |
|
|
|
|
|
|
|
|
|
|
|
"""py.test conftest.py file for package integration test.""" |
|
|
|
"""py.test conftest.py file for package integration test.""" |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import os |
|
|
|
|
|
|
|
|
|
|
|
import pytest |
|
|
|
import pytest |
|
|
|
|
|
|
|
|
|
|
|
from tests.testing.docker_wrapper import DockerWrapper |
|
|
|
from tests.testing.docker_wrapper import DockerWrapper |
|
|
@ -33,14 +35,17 @@ def docker_setup_teardown(): |
|
|
|
For more information about conftest.py see: |
|
|
|
For more information about conftest.py see: |
|
|
|
https://docs.pytest.org/en/latest/example/simple.html#package-directory-level-fixtures-setups |
|
|
|
https://docs.pytest.org/en/latest/example/simple.html#package-directory-level-fixtures-setups |
|
|
|
""" |
|
|
|
""" |
|
|
|
docker_wrapper = DockerWrapper( |
|
|
|
if os.environ.get("skip_launch_docker") == "true": |
|
|
|
image="apache/dolphinscheduler-standalone-server:ci", |
|
|
|
yield True |
|
|
|
container_name="ci-dolphinscheduler-standalone-server", |
|
|
|
else: |
|
|
|
) |
|
|
|
docker_wrapper = DockerWrapper( |
|
|
|
ports = {"25333/tcp": 25333} |
|
|
|
image="apache/dolphinscheduler-standalone-server:ci", |
|
|
|
container = docker_wrapper.run_until_log( |
|
|
|
container_name="ci-dolphinscheduler-standalone-server", |
|
|
|
log="Started StandaloneServer in", tty=True, ports=ports |
|
|
|
) |
|
|
|
) |
|
|
|
ports = {"25333/tcp": 25333} |
|
|
|
assert container is not None |
|
|
|
container = docker_wrapper.run_until_log( |
|
|
|
yield |
|
|
|
log="Started StandaloneServer in", tty=True, ports=ports |
|
|
|
docker_wrapper.remove_container() |
|
|
|
) |
|
|
|
|
|
|
|
assert container is not None |
|
|
|
|
|
|
|
yield |
|
|
|
|
|
|
|
docker_wrapper.remove_container() |
|
|
|