       (is (= (count data) (-> response :headers :content-length read-string)))
       (is (= data (:body response))))))
 
-(deftest websocket-as-channel
+(marktest websocket-as-channel
   ;; initialize the session
   (get-body (str (url)) :cookies nil)
   (let [result (promise)]

      (is (= "HELLO" (deref result 5000 :failure)))
      (is (= {:count 1 :ham :sandwich} (decode (get-body (str (url) "session"))))))))

(deftest nested-ws-routes
  (doseq [path ["" "foo" "foo/bar"]]
    (let [result (promise)]
      (with-open [socket (ws/connect (format "%snested-ws/%s" (url "ws") path)

        (is (= "Upgrade" (get-in m [:headers "connection"])))
        (is (= "k" (get-in m [:params "j"])))))))

(marktest response-charset-should-be-honored
  (doseq [charset ["UTF-8" "Shift_JIS" "ISO-8859-1" "UTF-16" "US-ASCII"]]
    (let [{:keys [headers raw-body]} (get-response (str (url) "charset?charset=" charset))]
      (is (= (read-string (headers "BodyBytes"))
            (into [] (.toByteArray raw-body)))))))

(when (in-container?)
  (marktest run-in-container-outside-of-init-should-throw
    (try
      (web/run identity)
      (is false)
