Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
change
sglang
Commits
9c574585
Unverified
Commit
9c574585
authored
May 24, 2025
by
Shi Shuai
Committed by
GitHub
May 23, 2025
Browse files
fix: remove content=none test when tool called (#6347)
parent
8233cc10
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
5 deletions
+0
-5
test/srt/test_function_calling.py
test/srt/test_function_calling.py
+0
-5
No files found.
test/srt/test_function_calling.py
View file @
9c574585
...
@@ -83,13 +83,8 @@ class TestOpenAIServerFunctionCalling(CustomTestCase):
...
@@ -83,13 +83,8 @@ class TestOpenAIServerFunctionCalling(CustomTestCase):
tools
=
tools
,
tools
=
tools
,
)
)
content
=
response
.
choices
[
0
].
message
.
content
tool_calls
=
response
.
choices
[
0
].
message
.
tool_calls
tool_calls
=
response
.
choices
[
0
].
message
.
tool_calls
assert
content
is
None
,
(
"When function call is successful, message.content should be None, "
f
"but got:
{
content
}
"
)
assert
(
assert
(
isinstance
(
tool_calls
,
list
)
and
len
(
tool_calls
)
>
0
isinstance
(
tool_calls
,
list
)
and
len
(
tool_calls
)
>
0
),
"tool_calls should be a non-empty list"
),
"tool_calls should be a non-empty list"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment