diff --git a/tests/conftest.py b/tests/conftest.py index be401d6..0f65598 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -11,9 +11,9 @@ "otelcol_fixtures", ] -NGINX_BINARY = os.getenv("TEST_NGINX_BINARY", "../nginx/objs/nginx") +NGINX = os.getenv("TEST_NGINX_BINARY", "../nginx/objs/nginx") CAPABILITIES = subprocess.check_output( - [NGINX_BINARY, "-V"], stderr=subprocess.STDOUT + [NGINX, "-V"], stderr=subprocess.STDOUT ).decode("utf-8") @@ -70,15 +70,7 @@ def nginx(testdir, nginx_config, _certs, logger): (testdir / "nginx.conf").write_text(nginx_config) logger.info("Starting nginx...") proc = subprocess.Popen( - [ - NGINX_BINARY, - "-p", - str(testdir), - "-c", - "nginx.conf", - "-e", - "error.log", - ] + [NGINX, "-p", str(testdir), "-c", "nginx.conf", "-e", "error.log"] ) logger.debug(f"args={' '.join(proc.args)}") logger.debug(f"pid={proc.pid}") diff --git a/tests/test_otel.py b/tests/test_otel.py index b2ffd9b..da3da2b 100644 --- a/tests/test_otel.py +++ b/tests/test_otel.py @@ -186,11 +186,7 @@ def _otelcol(testdir, logger): ) logger.info("Starting otelcol at 127.0.0.1:8317...") proc = subprocess.Popen( - [ - "../otelcol", - "--config", - testdir / "otel-config.yaml", - ] + ["../otelcol", "--config", testdir / "otel-config.yaml"] ) if proc.poll() is not None: raise subprocess.SubprocessError("Can't start otelcol")