fix: fix API tool integration test (#19187)

This commit is contained in:
Hao Cheng
2025-05-01 08:49:43 +02:00
committed by GitHub
parent 1ca6dbcdc8
commit bb1d1dc263
4 changed files with 9 additions and 3 deletions

View File

@@ -34,10 +34,11 @@ parameters = {
def test_api_tool(setup_http_mock):
tool = ApiTool(
entity=ToolEntity(
identity=ToolIdentity(provider="", author="", name="", label=I18nObject()),
identity=ToolIdentity(provider="", author="", name="", label=I18nObject(en_US="test tool")),
),
api_bundle=ApiToolBundle(**tool_bundle),
runtime=ToolRuntime(tenant_id="", credentials={"auth_type": "none"}),
provider_id="test_tool",
)
headers = tool.assembling_request(parameters)
response = tool.do_http_request(tool.api_bundle.server_url, tool.api_bundle.method, headers, parameters)