(self)
| 238 | assert tool.parameters["properties"]["value"]["description"] == "Value to look up" |
| 239 | |
| 240 | def test_function_style_requires_name(self): |
| 241 | class Params(BaseModel): |
| 242 | value: str |
| 243 | |
| 244 | with pytest.raises(ValueError, match="name is required"): |
| 245 | define_tool( |
| 246 | description="My tool", |
| 247 | handler=lambda params, inv: params.value.upper(), |
| 248 | params_type=Params, |
| 249 | ) |
| 250 | |
| 251 | |
| 252 | class TestNormalizeResult: |
nothing calls this directly
no test coverage detected