Skip to content

Commit b25a373

Browse files
Update tests/unittests/tools/mcp_tool/test_mcp_toolset.py
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
1 parent 63f9008 commit b25a373

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

tests/unittests/tools/mcp_tool/test_mcp_toolset.py

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -96,11 +96,14 @@ def test_error_log(self):
9696
toolset = MCPToolset(connection_params=self.mock_stdio_params)
9797
assert toolset.errlog == sys.stderr
9898

99-
def test_auth_credential_updates(self):
100-
"""Test setting auth credential."""
101-
toolset = MCPToolset(connection_params=self.mock_stdio_params)
102-
toolset._auth_credential = "test_auth_credential"
103-
assert toolset.auth_credential == "test_auth_credential"
99+
def test_auth_credential_with_value(self):
100+
"""Test getting auth credential when provided at initialization."""
101+
mock_credential = Mock(spec=AuthCredential)
102+
toolset = MCPToolset(
103+
connection_params=self.mock_stdio_params,
104+
auth_credential=mock_credential,
105+
)
106+
assert toolset.auth_credential == mock_credential
104107

105108
def test_init_with_stdio_connection_params(self):
106109
"""Test initialization with StdioConnectionParams."""

0 commit comments

Comments
 (0)