   (after (r/reset-database))
 
   (it "should return status code 404 at the root"
-    (should= 404 (:status (http-client/get "http://localhost:3000" {:throw-exceptions false}))))
+    (should= 404 (:status (http-get-request))))
 
   (context "circles"
     (context "when no circles have been created"
-      (with response (http-client/get "http://localhost:3000/circles" {:throw-exceptions false}))
+      (with response (http-get-request "circles"))
       (it "should return an empty array"
           (should= 200 (:status @response))
           (should= "[]" (:body @response))))
   
     (context "when creating a circle"
-      (with response (http-client/post "http://localhost:3000/circles" 
-                                      {:throw-exceptions false
-                                       :content-type :json
-                                       :body (json/generate-string 
-                                               {:name "Test Circle!"
-                                                :lead-link-name "Bill"
-                                                :lead-link-email "bfinn@example.com"})}))
+      (with response (http-post-request "circles" 
+                                        (json/generate-string 
+                                          {:name "Test Circle!"
+                                           :lead-link-name "Bill"
+                                           :lead-link-email "bfinn@example.com"})))
       (it "should redirect to the location of the newly created resource"
         (should= 303 (:status @response))
         (should-contain "application/json" (get-in @response [:headers "Content-Type"]))

            [clj-http.client :as http-client]
            [freefrog.rest :as r]))

(defn should-return-400 [spec-context circle-content response-content]
  (context spec-context
    (with response (http-client/post "http://localhost:3000/circles" 
                                    {:throw-exceptions false
                                     :content-type :json
                                     :body circle-content}))
    (it "should return a bad request"
      (should= 400 (:status @response))
      (should-contain response-content (:body @response)))))

                   (json/parse-string (:body @get-response)))))
  
    (context "when creating multiple circles"
      (before (http-post-request "circles" 
                                 (json/generate-string 
                                   {:name "Test Circle!"
                                    :lead-link-name "Bill"
                                    :lead-link-email "bfinn@example.com"})
                                 {:throw-exceptions true}))

      (before (http-post-request "circles" 
                                 (json/generate-string 
                                   {:name "Test Circle 2"
                                    :lead-link-name "Bill"
                                    :lead-link-email "bfinn@example.com"})
                                 {:throw-exceptions true}))

      (with get-response (http-get-request "circles"))

      (it "should return an array of created circles"
        (should= 200 (:status @get-response))
