test_get_buffer_string_xml_openai_image_url_data_skipped() — langchain Function Reference
Architecture documentation for the test_get_buffer_string_xml_openai_image_url_data_skipped() function in test_utils.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD cd9a3f25_0544_6066_566e_581f74490d48["test_get_buffer_string_xml_openai_image_url_data_skipped()"] 03f6a5ae_d57a_eb66_626a_b9e082b763ea["test_utils.py"] cd9a3f25_0544_6066_566e_581f74490d48 -->|defined in| 03f6a5ae_d57a_eb66_626a_b9e082b763ea style cd9a3f25_0544_6066_566e_581f74490d48 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/core/tests/unit_tests/messages/test_utils.py lines 2355–2371
def test_get_buffer_string_xml_openai_image_url_data_skipped() -> None:
"""Test XML format skips OpenAI-style `image_url` blocks with data: URLs."""
messages: list[BaseMessage] = [
HumanMessage(
content=[
{"type": "text", "text": "See this:"},
{
"type": "image_url",
"image_url": {"url": "data:image/jpeg;base64,/9j/4AAQ..."},
},
]
),
]
result = get_buffer_string(messages, format="xml")
assert "See this:" in result
assert "data:image" not in result
assert "/9j/4AAQ" not in result
Domain
Subdomains
Source
Frequently Asked Questions
What does test_get_buffer_string_xml_openai_image_url_data_skipped() do?
test_get_buffer_string_xml_openai_image_url_data_skipped() 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_openai_image_url_data_skipped() defined?
test_get_buffer_string_xml_openai_image_url_data_skipped() is defined in libs/core/tests/unit_tests/messages/test_utils.py at line 2355.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free