Home / Function/ test_structured_args() — langchain Function Reference

test_structured_args() — langchain Function Reference

Architecture documentation for the test_structured_args() function in test_tools.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  3647a285_3b6c_9f8e_a82c_cb997663270a["test_structured_args()"]
  8e7836ae_e72c_f670_72a5_4ca6d46e3555["test_tools.py"]
  3647a285_3b6c_9f8e_a82c_cb997663270a -->|defined in| 8e7836ae_e72c_f670_72a5_4ca6d46e3555
  style 3647a285_3b6c_9f8e_a82c_cb997663270a fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/core/tests/unit_tests/test_tools.py lines 130–137

def test_structured_args() -> None:
    """Test functionality with structured arguments."""
    structured_api = _MockStructuredTool()
    assert isinstance(structured_api, BaseTool)
    assert structured_api.name == "structured_api"
    expected_result = "1 True {'foo': 'bar'}"
    args = {"arg1": 1, "arg2": True, "arg3": {"foo": "bar"}}
    assert structured_api.run(args) == expected_result

Domain

Subdomains

Frequently Asked Questions

What does test_structured_args() do?
test_structured_args() is a function in the langchain codebase, defined in libs/core/tests/unit_tests/test_tools.py.
Where is test_structured_args() defined?
test_structured_args() is defined in libs/core/tests/unit_tests/test_tools.py at line 130.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free