MCPcopy Create free account
hub / github.com/AI45Lab/Code / test_mcp_server_config_with_env

Function test_mcp_server_config_with_env

core/src/mcp/protocol.rs:1176–1191  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1174
1175 #[test]
1176 fn test_mcp_server_config_with_env() {
1177 let mut env = HashMap::new();
1178 env.insert("API_KEY".to_string(), "secret".to_string());
1179 let config = McpServerConfig {
1180 name: "test-server".to_string(),
1181 transport: McpTransportConfig::Stdio {
1182 command: "node".to_string(),
1183 args: vec![],
1184 },
1185 enabled: true,
1186 env,
1187 oauth: None,
1188 tool_timeout_secs: 60,
1189 };
1190 assert!(config.env.contains_key("API_KEY"));
1191 }
1192
1193 #[test]
1194 fn test_mcp_server_config_with_oauth() {

Callers

nothing calls this directly

Calls 1

insertMethod · 0.45

Tested by

no test coverage detected