From 33a8e0254be46b24e990659ceaa85a4c0bc56916 Mon Sep 17 00:00:00 2001 From: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> Date: Mon, 24 Feb 2025 13:28:02 +0000 Subject: [PATCH] test: update invalid arguments test to expect ValueError Co-Authored-By: Joe Moura --- tests/tools/test_tool_usage.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/tools/test_tool_usage.py b/tests/tools/test_tool_usage.py index 8a7444d53..d78e2feb5 100644 --- a/tests/tools/test_tool_usage.py +++ b/tests/tools/test_tool_usage.py @@ -288,7 +288,7 @@ class TestWebSocketToolUsage: arguments={}, log="Test log", ) - with pytest.raises(ValueError): + with pytest.raises(ValueError, match="Tool arguments cannot be empty"): tool_usage.use(calling, "Test string") # Test with None arguments @@ -297,8 +297,8 @@ class TestWebSocketToolUsage: arguments=None, log="Test log", ) - result = tool_usage.use(calling, "Test string") - assert "error" in result.lower() + with pytest.raises(ValueError, match="Tool arguments cannot be empty"): + tool_usage.use(calling, "Test string") def test_validate_tool_input_booleans_and_none():