[misc][ci] fix cpu test with plugins (#7489)
This commit is contained in:
@@ -4,12 +4,10 @@ import pytest
|
||||
|
||||
from vllm import LLM, SamplingParams
|
||||
|
||||
# NOTE: the order of the tests is important
|
||||
# the first test does not load any plugins
|
||||
# the second test loads the plugin
|
||||
# they share the same process, so the plugin is loaded for the second test
|
||||
from ..utils import fork_new_process_for_each_test
|
||||
|
||||
|
||||
@fork_new_process_for_each_test
|
||||
def test_plugin(dummy_opt_path):
|
||||
os.environ["VLLM_PLUGINS"] = ""
|
||||
with pytest.raises(Exception) as excinfo:
|
||||
@@ -17,6 +15,7 @@ def test_plugin(dummy_opt_path):
|
||||
assert "are not supported for now" in str(excinfo.value)
|
||||
|
||||
|
||||
@fork_new_process_for_each_test
|
||||
def test_oot_registration(dummy_opt_path):
|
||||
os.environ["VLLM_PLUGINS"] = "register_dummy_model"
|
||||
prompts = ["Hello, my name is", "The text does not matter"]
|
||||
|
||||
Reference in New Issue
Block a user