Home / Function/ test_get_buffer_string_xml_custom_separator() — langchain Function Reference

test_get_buffer_string_xml_custom_separator() — langchain Function Reference

Architecture documentation for the test_get_buffer_string_xml_custom_separator() function in test_utils.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  1e7a56fa_c52a_8aa1_17fe_f4c3276c31c9["test_get_buffer_string_xml_custom_separator()"]
  ea3f8d89_f44b_6738_3cb9_a740a73cfca4["test_utils.py"]
  1e7a56fa_c52a_8aa1_17fe_f4c3276c31c9 -->|defined in| ea3f8d89_f44b_6738_3cb9_a740a73cfca4
  style 1e7a56fa_c52a_8aa1_17fe_f4c3276c31c9 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/core/tests/unit_tests/messages/test_utils.py lines 1930–1940

def test_get_buffer_string_xml_custom_separator() -> None:
    """Test XML format with custom message separator."""
    messages = [
        HumanMessage(content="Hello"),
        AIMessage(content="Hi there"),
    ]
    result = get_buffer_string(messages, format="xml", message_separator="\n\n")
    expected = (
        '<message type="human">Hello</message>\n\n<message type="ai">Hi there</message>'
    )
    assert result == expected

Subdomains

Frequently Asked Questions

What does test_get_buffer_string_xml_custom_separator() do?
test_get_buffer_string_xml_custom_separator() is a function in the langchain codebase, defined in libs/core/tests/unit_tests/messages/test_utils.py.
Where is test_get_buffer_string_xml_custom_separator() defined?
test_get_buffer_string_xml_custom_separator() is defined in libs/core/tests/unit_tests/messages/test_utils.py at line 1930.

Analyze Your Own Codebase

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

Try Supermodel Free