🌟 The Multi-Agent Framework: First AI Software Company, Towards Natural Language Programming
update function_rsps.
刘棒棒1793a5fec64c
diff --git a/tests/metagpt/provider/test_openai.py b/tests/metagpt/provider/test_openai.pyindex 7af2f6892..2e5799475 100644--- a/tests/metagpt/provider/test_openai.py+++ b/tests/metagpt/provider/test_openai.py@@ -66,11 +66,17 @@ class TestOpenAI:@pytest.fixturedef tool_calls_rsp(self):function_rsps = [- Function(arguments='{\n"language": "python",\n"code": "print(\'hello world\')"', name="execute"),- Function(arguments='{\n"language": "python",\n"code": ```print("hello world")```', name="execute"),- Function(arguments='{\n"language": "python",\n"code": \'print("hello world")\'', name="execute"),- Function(arguments='{\n"language": \'python\',\n"code": "print(\'hello world\')"', name="execute"),+ Function(arguments='{\n"language": "python",\n"code": "print(\'hello world\')"}', name="execute"),+ Function(arguments='{\n"language": "python",\n"code": \'print("hello world")\'}', name="execute"),+ Function(arguments='{\n"language": \'python\',\n"code": "print(\'hello world\')"}', name="execute"),+ Function(arguments='{\n"language": "python",\n"code": "print(\'hello world\')"}', name="execute"),+ Function(arguments='{\n"language": "python",\n"code": ```print("hello world")```}', name="execute"),+ Function(arguments='{\n"language": "python",\n"code": """print("hello world")"""}', name="execute"),Function(arguments='\nprint("hello world")\\n', name="execute"),+ # only `{` in arguments+ Function(arguments='{\n"language": "python",\n"code": "print(\'hello world\')"', name="execute"),+ # no `{`, `}` in arguments+ Function(arguments='\n"language": "python",\n"code": "print(\'hello world\')"', name="execute"),]tool_calls = [ChatCompletionMessageToolCall(type="function", id=f"call_{i}", function=f)