         (is (= (:server-name request-map) "127.0.0.1"))
         (is (= (:server-port request-map) 5050))
         (is (= (:ssl-client-cert request-map) nil))))))
+
+(deftest custom-content-type
+  (with-ring-server (content-type-handler "text/plain;charset=UTF-16;version=1")
+    (let [response (http/get base-url)]
+      (is (= (get-in response [:headers "content-type"])
+             "text/plain;charset=UTF-16;version=1")))))

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

(deftest request-get
  (with-ring-server echo-rhandler
    (let [response (http/get base-url {:basic-auth ["user" "password"]})
          request-map (read-request response)]
      (is (= (:request-method request-map) :get))

       ~@body
       (finally (.stop server#)))))

(defn echo-handler
  [request]
  {:status 200
   :headers {"request-map" (pr-str (dissoc request :body))}
   :body (:body request)})

(defn content-type-handler
  [content-type]
  (fn [request]
    {:status  200
     :headers {"Content-Type" content-type}
     :body    ""}))

(defn read-request
  [response]
