 
 (defcoretest telling-the-application-to-chill-out
   [_ ch2 ch3]
-  (fn [resp req]
-    (resp :response [200 {"content-length" "5"} "Hello"])
-    (resp :pause nil)
-    (receive-all ch3 (fn [_] (resp :resume nil)))
-    (fn [evt val] true))
+  (fn [downstream]
+    (fn [evt val]
+      (when (= :request evt)
+        (downstream :response [200 {"content-length" "5"} "Hello"])
+        (downstream :pause nil)
+        (receive-all ch3 (fn [_] (downstream :resume nil))))))
 
   (let [latch (atom true)]
     (client/request


(defcoretest issuing-pause-resume
  [_ ch2 ch3]
  (fn [resp req]
    (resp :response [200 {"transfer-encoding" "chunked"} :chunked])
    (resp :body "Hello")
    (resp :body "World")
    (resp :done nil)
    (fn [_ _] true))

  (let [upstream
        (client/request


(defcoretest handling-100-continue-requests-and-responses
  [ch1 ch2]
  (deftrackedapp [downstream]
    (fn [evt val]
      (when (= :request evt)
        (downstream :response [100]))
      (when (= :done evt)
        (downstream
         :response
         [200 {"content-length" "5" "connection" "close"} "Hello"]))))

