### What this PR does / why we need it?
**Scope of Changes**:
| File Path |
| :--- |
| `tests/e2e/310p/multicard/test_vl_model_multicard.py` |
| `tests/e2e/310p/singlecard/test_vl_model_singlecard.py` |
| `tests/e2e/310p/test_utils.py` |
| `tests/e2e/conftest.py` |
| `tests/e2e/model_utils.py` |
| `tests/e2e/models/conftest.py` |
| `tests/e2e/models/test_lm_eval_correctness.py` |
| `tests/e2e/multicard/2-cards/spec_decode/test_spec_decode.py` |
| `tests/e2e/multicard/2-cards/test_aclgraph_capture_replay.py` |
| `tests/e2e/multicard/2-cards/test_data_parallel.py` |
| `tests/e2e/multicard/2-cards/test_disaggregated_encoder.py` |
| `tests/e2e/multicard/2-cards/test_expert_parallel.py` |
| `tests/e2e/multicard/2-cards/test_external_launcher.py` |
| `tests/e2e/multicard/2-cards/test_full_graph_mode.py` |
| `tests/e2e/multicard/2-cards/test_ilama_lora_tp2.py` |
| `tests/e2e/multicard/2-cards/test_offline_inference_distributed.py` |
| `tests/e2e/multicard/2-cards/test_offline_weight_load.py` |
| `tests/e2e/multicard/2-cards/test_pipeline_parallel.py` |
| `tests/e2e/multicard/2-cards/test_prefix_caching.py` |
| `tests/e2e/multicard/2-cards/test_quantization.py` |
| `tests/e2e/multicard/2-cards/test_qwen3_moe.py` |
| `tests/e2e/multicard/2-cards/test_qwen3_moe_routing_replay.py` |
| `tests/e2e/multicard/2-cards/test_qwen3_performance.py` |
| `tests/e2e/multicard/2-cards/test_shared_expert_dp.py` |
| `tests/e2e/multicard/2-cards/test_single_request_aclgraph.py` |
| `tests/e2e/multicard/2-cards/test_sp_pass.py` |
### Does this PR introduce _any_ user-facing change?
### How was this patch tested?
- vLLM version: v0.15.0
- vLLM main:
9562912cea
Signed-off-by: MrZ20 <2609716663@qq.com>
Co-authored-by: wangxiyuan <wangxiyuan1007@gmail.com>
69 lines
2.1 KiB
Python
69 lines
2.1 KiB
Python
# SPDX-License-Identifier: Apache-2.0
|
|
# SPDX-FileCopyrightText: Copyright contributors to the vLLM project
|
|
from pathlib import Path
|
|
|
|
import pytest
|
|
|
|
|
|
def pytest_addoption(parser):
|
|
parser.addoption(
|
|
"--config-list-file",
|
|
action="store",
|
|
default=None,
|
|
help="Path to the file listing model config YAMLs (one per line)",
|
|
)
|
|
parser.addoption(
|
|
"--tp-size",
|
|
action="store",
|
|
default="1",
|
|
help="Tensor parallel size to use for evaluation",
|
|
)
|
|
parser.addoption(
|
|
"--config",
|
|
action="store",
|
|
default="./tests/e2e/models/configs/Qwen3-8B.yaml",
|
|
help="Path to the model config YAML file",
|
|
)
|
|
parser.addoption(
|
|
"--report-dir",
|
|
action="store",
|
|
default="./benchmarks/accuracy",
|
|
help="Directory to store report files",
|
|
)
|
|
|
|
|
|
@pytest.fixture(scope="session")
|
|
def config_list_file(pytestconfig, config_dir):
|
|
rel_path = pytestconfig.getoption("--config-list-file")
|
|
return config_dir / rel_path
|
|
|
|
|
|
@pytest.fixture(scope="session")
|
|
def tp_size(pytestconfig):
|
|
return pytestconfig.getoption("--tp-size")
|
|
|
|
|
|
@pytest.fixture(scope="session")
|
|
def config(pytestconfig):
|
|
return pytestconfig.getoption("--config")
|
|
|
|
|
|
@pytest.fixture(scope="session")
|
|
def report_dir(pytestconfig):
|
|
return pytestconfig.getoption("report_dir")
|
|
|
|
|
|
def pytest_generate_tests(metafunc):
|
|
if "config_filename" in metafunc.fixturenames:
|
|
if metafunc.config.getoption("--config-list-file"):
|
|
rel_path = metafunc.config.getoption("--config-list-file")
|
|
config_list_file = Path(rel_path).resolve()
|
|
config_dir = config_list_file.parent
|
|
with open(config_list_file, encoding="utf-8") as f:
|
|
configs = [config_dir / line.strip() for line in f if line.strip() and not line.startswith("#")]
|
|
metafunc.parametrize("config_filename", configs)
|
|
else:
|
|
single_config = metafunc.config.getoption("--config")
|
|
config_path = Path(single_config).resolve()
|
|
metafunc.parametrize("config_filename", [config_path])
|