Home / Function/ test_tool_retry_initialization_with_base_tools() — langchain Function Reference

test_tool_retry_initialization_with_base_tools() — langchain Function Reference

Architecture documentation for the test_tool_retry_initialization_with_base_tools() function in test_tool_retry.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  7d82c376_aaae_c98c_9576_c7f63ad47b2c["test_tool_retry_initialization_with_base_tools()"]
  c71b26df_821f_59ac_c7ef_3b96fcbe0d5b["test_tool_retry.py"]
  7d82c376_aaae_c98c_9576_c7f63ad47b2c -->|defined in| c71b26df_821f_59ac_c7ef_3b96fcbe0d5b
  style 7d82c376_aaae_c98c_9576_c7f63ad47b2c fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/langchain_v1/tests/unit_tests/agents/middleware/implementations/test_tool_retry.py lines 103–113

def test_tool_retry_initialization_with_base_tools() -> None:
    """Test ToolRetryMiddleware initialization with BaseTool instances."""
    retry = ToolRetryMiddleware(
        max_retries=3,
        tools=[working_tool, failing_tool],  # Pass BaseTool instances
    )

    assert retry.max_retries == 3
    # Should extract names from BaseTool instances
    assert retry._tool_filter == ["working_tool", "failing_tool"]
    assert retry.tools == []

Domain

Subdomains

Frequently Asked Questions

What does test_tool_retry_initialization_with_base_tools() do?
test_tool_retry_initialization_with_base_tools() is a function in the langchain codebase, defined in libs/langchain_v1/tests/unit_tests/agents/middleware/implementations/test_tool_retry.py.
Where is test_tool_retry_initialization_with_base_tools() defined?
test_tool_retry_initialization_with_base_tools() is defined in libs/langchain_v1/tests/unit_tests/agents/middleware/implementations/test_tool_retry.py at line 103.

Analyze Your Own Codebase

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

Try Supermodel Free