From 6bb00745879b9b01d49d12963231bbb23c96bd93 Mon Sep 17 00:00:00 2001 From: openhands Date: Tue, 22 Apr 2025 14:12:11 +0000 Subject: [PATCH] Fix test_make_tool_all_tools to skip test mock classes --- test/serena/test_mcp.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/test/serena/test_mcp.py b/test/serena/test_mcp.py index 0e90e762..31182f0c 100644 --- a/test/serena/test_mcp.py +++ b/test/serena/test_mcp.py @@ -245,6 +245,11 @@ def test_make_tool_all_tools() -> None: if tool_class.__name__ == "Tool" or getattr(tool_class, "__abstractmethods__", set()): continue + # Skip test mock classes that don't properly implement __init__ + if tool_class.__name__ in ["BaseMockTool", "BadTool", "NoParamsTool", "NoReturnTool", + "MissingParamTool", "ComplexDocTool", "FormatTool", "NoDescriptionTool"]: + continue + # Create an instance of the tool tool_instance = tool_class(MockAgent())