From 398ae95b96e07e6a44a03340310fef4d982b2467 Mon Sep 17 00:00:00 2001 From: wangyu <53896905+yenuo26@users.noreply.github.com> Date: Thu, 5 Feb 2026 10:54:40 +0800 Subject: [PATCH] [CI] Add CI branch coverage calculation, fix statement coverage results and add log before test for buildkite log group (#1120) Signed-off-by: wangyu31577 Co-authored-by: wangyu31577 --- .buildkite/pipeline.yml | 19 +++++++++++++------ pyproject.toml | 6 +----- tests/conftest.py | 6 ++++++ 3 files changed, 20 insertions(+), 11 deletions(-) diff --git a/.buildkite/pipeline.yml b/.buildkite/pipeline.yml index 402e62518..e02d49472 100644 --- a/.buildkite/pipeline.yml +++ b/.buildkite/pipeline.yml @@ -20,12 +20,19 @@ steps: - label: "Simple Unit Test" depends_on: image-build commands: - - pytest -v -s tests/entrypoints/ - - pytest -v -s tests/diffusion/cache/ - - pytest -v -s tests/diffusion/lora/ - - pytest -v -s tests/model_executor/models/qwen2_5_omni/test_audio_length.py - - pytest -v -s tests/worker/ - - pytest -v -s tests/distributed/omni_connectors/test_kv_flow.py + - | + pytest -v -s \ + tests/entrypoints/ \ + tests/diffusion/cache/ \ + tests/diffusion/lora/ \ + tests/model_executor/models/qwen2_5_omni/test_audio_length.py \ + tests/worker/ \ + tests/distributed/omni_connectors/test_kv_flow.py \ + --cov=vllm_omni \ + --cov-branch \ + --cov-report=term-missing \ + --cov-report=html \ + --cov-report=xml agents: queue: "gpu_1_queue" plugins: diff --git a/pyproject.toml b/pyproject.toml index de35d45a3..af13606c5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -155,11 +155,7 @@ python_classes = ["Test*"] python_functions = ["test_*"] addopts = [ "--strict-markers", - "--strict-config", - "--cov=vllm_omni", - "--cov-report=term-missing", - "--cov-report=html", - "--cov-report=xml", + "--strict-config" ] markers = [ # ci/cd required diff --git a/tests/conftest.py b/tests/conftest.py index b1d7e6cc8..84fbb91b7 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -60,6 +60,12 @@ def clean_gpu_memory_between_tests(): _run_post_test_cleanup() +@pytest.fixture(autouse=True) +def log_test_name_before_test(request): + print(f"--- Running test: {request.node.name}") + yield + + def _run_pre_test_cleanup(enable_force=False): if os.getenv("VLLM_TEST_CLEAN_GPU_MEMORY", "0") != "1" and not enable_force: print("GPU cleanup disabled")