Skip to content

Commit 7341bcb

Browse files
committed
Fix regex pattern in test to use raw string
- Use raw string for regex pattern with metacharacters (RUF043) - Fixes pytest.raises match parameter for AttributeError test
1 parent 7e5ad2f commit 7341bcb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tests/test_extension.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ def test_load_function_from_string_invalid_function(self):
234234
"""Test loading non-existent functions from valid modules."""
235235
extension = MCPExtensionApp()
236236

237-
with pytest.raises(AttributeError, match="Function.*not found"):
237+
with pytest.raises(AttributeError, match=r"Function.*not found"):
238238
extension._load_function_from_string("os:nonexistent_function")
239239

240240
def test_load_function_with_nested_module(self):

0 commit comments

Comments
 (0)