|
18 | 18 | from aws_mcp_proxy.utils import ( |
19 | 19 | create_transport_with_sigv4, |
20 | 20 | determine_service_name, |
21 | | - normalize_endpoint_url, |
22 | 21 | ) |
23 | 22 | from fastmcp.client.transports import StreamableHttpTransport |
24 | 23 | from unittest.mock import MagicMock, patch |
@@ -85,40 +84,6 @@ def test_create_transport_with_sigv4_no_profile(self, mock_create_sigv4_client): |
85 | 84 | assert result is not None |
86 | 85 |
|
87 | 86 |
|
88 | | -class TestNormalizeEndpointUrl: |
89 | | - """Test cases for normalize_endpoint_url function (lines 151-153).""" |
90 | | - |
91 | | - def test_normalize_endpoint_url_default_path(self): |
92 | | - """Test normalizing endpoint URL with default /mcp path.""" |
93 | | - endpoint = 'https://eks-mcp.us-west-2.api.aws' |
94 | | - result = normalize_endpoint_url(endpoint) |
95 | | - assert result == 'https://eks-mcp.us-west-2.api.aws/mcp' |
96 | | - |
97 | | - def test_normalize_endpoint_url_custom_path(self): |
98 | | - """Test normalizing endpoint URL with custom path.""" |
99 | | - endpoint = 'https://eks-mcp.us-west-2.api.aws' |
100 | | - result = normalize_endpoint_url(endpoint, '/api/v1') |
101 | | - assert result == 'https://eks-mcp.us-west-2.api.aws/api/v1' |
102 | | - |
103 | | - def test_normalize_endpoint_url_trailing_slash(self): |
104 | | - """Test normalizing endpoint URL that already has trailing slash.""" |
105 | | - endpoint = 'https://eks-mcp.us-west-2.api.aws/' |
106 | | - result = normalize_endpoint_url(endpoint) |
107 | | - assert result == 'https://eks-mcp.us-west-2.api.aws/mcp' |
108 | | - |
109 | | - def test_normalize_endpoint_url_already_has_path(self): |
110 | | - """Test normalizing endpoint URL that already has the path.""" |
111 | | - endpoint = 'https://eks-mcp.us-west-2.api.aws/mcp' |
112 | | - result = normalize_endpoint_url(endpoint) |
113 | | - assert result == 'https://eks-mcp.us-west-2.api.aws/mcp' |
114 | | - |
115 | | - def test_normalize_endpoint_url_different_existing_path(self): |
116 | | - """Test normalizing endpoint URL that has a different existing path.""" |
117 | | - endpoint = 'https://eks-mcp.us-west-2.api.aws/api' |
118 | | - result = normalize_endpoint_url(endpoint) |
119 | | - assert result == 'https://eks-mcp.us-west-2.api.aws/api/mcp' |
120 | | - |
121 | | - |
122 | 87 | class TestValidateRequiredArgs: |
123 | 88 | """Test cases for validate_service_name function.""" |
124 | 89 |
|
|
0 commit comments