@@ -76,21 +76,18 @@ async def generate(engine: AsyncLLM,
76
76
77
77
@pytest .mark .parametrize (
78
78
"output_kind" , [RequestOutputKind .DELTA , RequestOutputKind .FINAL_ONLY ])
79
- @pytest .mark .parametrize ("engine_args_and_prompt " ,
79
+ @pytest .mark .parametrize ("engine_args,prompt " ,
80
80
[(TEXT_ENGINE_ARGS , TEXT_PROMPT ),
81
81
(VISION_ENGINE_ARGS , VISION_PROMPT )])
82
82
@pytest .mark .asyncio
83
- async def test_load (
84
- monkeypatch : pytest .MonkeyPatch ,
85
- output_kind : RequestOutputKind ,
86
- engine_args_and_prompt : tuple [AsyncEngineArgs , PromptType ],
87
- ):
83
+ async def test_load (monkeypatch : pytest .MonkeyPatch ,
84
+ output_kind : RequestOutputKind ,
85
+ engine_args : AsyncEngineArgs , prompt : PromptType ):
88
86
# TODO(rickyx): Remove monkeypatch once we have a better way to test V1
89
87
# so that in the future when we switch, we don't have to change all the
90
88
# tests.
91
89
with monkeypatch .context () as m , ExitStack () as after :
92
90
m .setenv ("VLLM_USE_V1" , "1" )
93
- engine_args , prompt = engine_args_and_prompt
94
91
95
92
engine = AsyncLLM .from_engine_args (engine_args )
96
93
after .callback (engine .shutdown )
@@ -124,18 +121,16 @@ async def test_load(
124
121
125
122
@pytest .mark .parametrize (
126
123
"output_kind" , [RequestOutputKind .DELTA , RequestOutputKind .FINAL_ONLY ])
127
- @pytest .mark .parametrize ("engine_args_and_prompt " ,
124
+ @pytest .mark .parametrize ("engine_args,prompt " ,
128
125
[(TEXT_ENGINE_ARGS , TEXT_PROMPT ),
129
126
(VISION_ENGINE_ARGS , VISION_PROMPT )])
130
127
@pytest .mark .asyncio
131
128
async def test_abort (monkeypatch : pytest .MonkeyPatch ,
132
129
output_kind : RequestOutputKind ,
133
- engine_args_and_prompt : tuple [AsyncEngineArgs ,
134
- PromptType ]):
130
+ engine_args : AsyncEngineArgs , prompt : PromptType ):
135
131
136
132
with monkeypatch .context () as m , ExitStack () as after :
137
133
m .setenv ("VLLM_USE_V1" , "1" )
138
- engine_args , prompt = engine_args_and_prompt
139
134
140
135
engine = AsyncLLM .from_engine_args (engine_args )
141
136
after .callback (engine .shutdown )
@@ -193,17 +188,15 @@ async def test_abort(monkeypatch: pytest.MonkeyPatch,
193
188
194
189
195
190
@pytest .mark .parametrize ("n" , [1 , 3 ])
196
- @pytest .mark .parametrize ("engine_args_and_prompt " ,
191
+ @pytest .mark .parametrize ("engine_args,prompt " ,
197
192
[(TEXT_ENGINE_ARGS , TEXT_PROMPT ),
198
193
(VISION_ENGINE_ARGS , VISION_PROMPT )])
199
194
@pytest .mark .asyncio
200
- async def test_finished_flag (monkeypatch , n : int ,
201
- engine_args_and_prompt : tuple [AsyncEngineArgs ,
202
- PromptType ]):
195
+ async def test_finished_flag (monkeypatch : pytest .MonkeyPatch , n : int ,
196
+ engine_args : AsyncEngineArgs , prompt : PromptType ):
203
197
204
198
with monkeypatch .context () as m , ExitStack () as after :
205
199
m .setenv ("VLLM_USE_V1" , "1" )
206
- engine_args , prompt = engine_args_and_prompt
207
200
208
201
engine = AsyncLLM .from_engine_args (engine_args )
209
202
after .callback (engine .shutdown )
0 commit comments