Home / Function/ test_parse_url_with_auth_with_path_and_query() — langchain Function Reference

test_parse_url_with_auth_with_path_and_query() — langchain Function Reference

Architecture documentation for the test_parse_url_with_auth_with_path_and_query() function in test_auth.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  581bfe60_b639_1507_d3da_984a86503d91["test_parse_url_with_auth_with_path_and_query()"]
  32235838_c616_6ae7_3819_7800d606b299["TestParseUrlWithAuth"]
  581bfe60_b639_1507_d3da_984a86503d91 -->|defined in| 32235838_c616_6ae7_3819_7800d606b299
  style 581bfe60_b639_1507_d3da_984a86503d91 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/partners/ollama/tests/unit_tests/test_auth.py lines 40–50

    def test_parse_url_with_auth_with_path_and_query(self) -> None:
        """Test URLs with auth, path, and query parameters."""
        url = "https://user:pass@ollama.example.com:11434/api/v1?timeout=30"
        cleaned_url, headers = parse_url_with_auth(url)

        expected_url = "https://ollama.example.com:11434/api/v1?timeout=30"
        expected_credentials = base64.b64encode(b"user:pass").decode()
        expected_headers = {"Authorization": f"Basic {expected_credentials}"}

        assert cleaned_url == expected_url
        assert headers == expected_headers

Domain

Subdomains

Frequently Asked Questions

What does test_parse_url_with_auth_with_path_and_query() do?
test_parse_url_with_auth_with_path_and_query() is a function in the langchain codebase, defined in libs/partners/ollama/tests/unit_tests/test_auth.py.
Where is test_parse_url_with_auth_with_path_and_query() defined?
test_parse_url_with_auth_with_path_and_query() is defined in libs/partners/ollama/tests/unit_tests/test_auth.py at line 40.

Analyze Your Own Codebase

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

Try Supermodel Free