Home / Function/ test_fireworks_api_key_masked_when_passed_via_constructor() — langchain Function Reference

test_fireworks_api_key_masked_when_passed_via_constructor() — langchain Function Reference

Architecture documentation for the test_fireworks_api_key_masked_when_passed_via_constructor() function in test_llms.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  ad2d9f91_38d2_f145_88da_e7ab0e4b0c60["test_fireworks_api_key_masked_when_passed_via_constructor()"]
  9a53709e_8202_5be7_e42c_f8989b683717["test_llms.py"]
  ad2d9f91_38d2_f145_88da_e7ab0e4b0c60 -->|defined in| 9a53709e_8202_5be7_e42c_f8989b683717
  style ad2d9f91_38d2_f145_88da_e7ab0e4b0c60 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/partners/fireworks/tests/unit_tests/test_llms.py lines 47–60

def test_fireworks_api_key_masked_when_passed_via_constructor(
    capsys: CaptureFixture,
) -> None:
    """Test that the API key is masked when passed via the constructor."""
    llm = Fireworks(  # type: ignore[call-arg]
        fireworks_api_key="secret-api-key",
        model="accounts/fireworks/models/mixtral-8x7b-instruct",
        temperature=0.2,
        max_tokens=250,
    )
    print(llm.fireworks_api_key, end="")  # noqa: T201
    captured = capsys.readouterr()

    assert captured.out == "**********"

Domain

Subdomains

Frequently Asked Questions

What does test_fireworks_api_key_masked_when_passed_via_constructor() do?
test_fireworks_api_key_masked_when_passed_via_constructor() is a function in the langchain codebase, defined in libs/partners/fireworks/tests/unit_tests/test_llms.py.
Where is test_fireworks_api_key_masked_when_passed_via_constructor() defined?
test_fireworks_api_key_masked_when_passed_via_constructor() is defined in libs/partners/fireworks/tests/unit_tests/test_llms.py at line 47.

Analyze Your Own Codebase

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

Try Supermodel Free