@@ -43,6 +43,7 @@ class HTTP1ProxyConnectHandlerTests: XCTestCase {
4343
4444 XCTAssertEqual ( head. method, . CONNECT)
4545 XCTAssertEqual ( head. uri, " swift.org:443 " )
46+ XCTAssertEqual ( head. headers [ " host " ] . first, " swift.org " )
4647 XCTAssertNil ( head. headers [ " proxy-authorization " ] . first)
4748 XCTAssertEqual ( try embedded. readOutbound ( as: HTTPClientRequestPart . self) , . end( nil ) )
4849
@@ -76,6 +77,7 @@ class HTTP1ProxyConnectHandlerTests: XCTestCase {
7677
7778 XCTAssertEqual ( head. method, . CONNECT)
7879 XCTAssertEqual ( head. uri, " swift.org:443 " )
80+ XCTAssertEqual ( head. headers [ " host " ] . first, " swift.org " )
7981 XCTAssertEqual ( head. headers [ " proxy-authorization " ] . first, " Basic abc123 " )
8082 XCTAssertEqual ( try embedded. readOutbound ( as: HTTPClientRequestPart . self) , . end( nil ) )
8183
@@ -109,6 +111,7 @@ class HTTP1ProxyConnectHandlerTests: XCTestCase {
109111
110112 XCTAssertEqual ( head. method, . CONNECT)
111113 XCTAssertEqual ( head. uri, " swift.org:443 " )
114+ XCTAssertEqual ( head. headers [ " host " ] . first, " swift.org " )
112115 XCTAssertNil ( head. headers [ " proxy-authorization " ] . first)
113116 XCTAssertEqual ( try embedded. readOutbound ( as: HTTPClientRequestPart . self) , . end( nil ) )
114117
@@ -148,6 +151,7 @@ class HTTP1ProxyConnectHandlerTests: XCTestCase {
148151
149152 XCTAssertEqual ( head. method, . CONNECT)
150153 XCTAssertEqual ( head. uri, " swift.org:443 " )
154+ XCTAssertEqual ( head. headers [ " host " ] . first, " swift.org " )
151155 XCTAssertNil ( head. headers [ " proxy-authorization " ] . first)
152156 XCTAssertEqual ( try embedded. readOutbound ( as: HTTPClientRequestPart . self) , . end( nil ) )
153157
@@ -187,6 +191,7 @@ class HTTP1ProxyConnectHandlerTests: XCTestCase {
187191
188192 XCTAssertEqual ( head. method, . CONNECT)
189193 XCTAssertEqual ( head. uri, " swift.org:443 " )
194+ XCTAssertEqual ( head. headers [ " host " ] . first, " swift.org " )
190195 XCTAssertEqual ( try embedded. readOutbound ( as: HTTPClientRequestPart . self) , . end( nil ) )
191196
192197 let responseHead = HTTPResponseHead ( version: . http1_1, status: . ok)
0 commit comments