partners[anthropic]: update unit test for key passed in from the environment (#21290)

**Description:** Update unit test for ChatAnthropic
**Issue:** Test for key passed in from the environment should not have
the key initialized in the constructor
**Dependencies:** None
pull/21315/head
aditya thomas 2 months ago committed by GitHub
parent d310f9c71e
commit b868c78a12
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -438,7 +438,6 @@ def test_anthropic_api_key_masked_when_passed_from_env(
monkeypatch.setenv("ANTHROPIC_API_KEY ", "secret-api-key")
chat_model = ChatAnthropic(
model="claude-3-opus-20240229",
anthropic_api_key="secret-api-key",
)
print(chat_model.anthropic_api_key, end="") # noqa: T201
captured = capsys.readouterr()

Loading…
Cancel
Save