Skip to content

Commit 6ec05ad

Browse files
committed
Cleanup HTTP client in Unix socket test
1 parent 6cc7ad8 commit 6ec05ad

1 file changed

Lines changed: 4 additions & 6 deletions

File tree

  • ring-jetty-adapter/test/ring/adapter/test

ring-jetty-adapter/test/ring/adapter/test/jetty.clj

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -120,12 +120,10 @@
120120
(with-server hello-world {:http? false
121121
:unix-socket test-unix-domain-socket}
122122
(let [path (Paths/get test-unix-domain-socket (make-array String 0))
123-
transport (HttpClientTransportOverHTTP. (ClientConnector.))
124-
client (doto (HttpClient. transport) (.start))
125-
response (-> client
126-
(.newRequest "http://localhost")
127-
(.transport (Transport$TCPUnix. path))
128-
(.send))]
123+
response (-> (doto (HttpClient.) (.start))
124+
(.newRequest "http://localhost")
125+
(.transport (Transport$TCPUnix. path))
126+
(.send))]
129127
(is (= (.getStatus response) 200))
130128
(is (.getMediaType response) "text/plain")
131129
(is (= (.getContentAsString response) "Hello World")))))))

0 commit comments

Comments
 (0)