[Test] Refactor hard coded device string in test files under compile/quantization/models/model_executor folders (#38901)
Signed-off-by: Liao, Wei <wei.liao@intel.com>
This commit is contained in:
@@ -34,6 +34,8 @@ from vllm.config.vllm import (
|
||||
)
|
||||
from vllm.platforms import current_platform
|
||||
|
||||
DEVICE_TYPE = current_platform.device_type
|
||||
|
||||
|
||||
def test_compile_config_repr_succeeds():
|
||||
# setup: VllmBackend mutates the config object
|
||||
@@ -504,8 +506,8 @@ def test_generation_config_loading():
|
||||
@pytest.mark.parametrize(
|
||||
"pt_load_map_location",
|
||||
[
|
||||
"cuda",
|
||||
{"": "cuda"},
|
||||
DEVICE_TYPE,
|
||||
{"": DEVICE_TYPE},
|
||||
],
|
||||
)
|
||||
def test_load_config_pt_load_map_location(pt_load_map_location):
|
||||
|
||||
Reference in New Issue
Block a user