                 (make-request waiter-url "/state" :headers {"origin" "badorigin.com"} :method :post)]
             (is (= 403 status) response))
           (let [{:keys [status] :as response}
-                (make-request waiter-url "/state" :headers {"origin" "badorigin.com"} :method :options )]
+                (make-request waiter-url "/state" :headers {"origin" "badorigin.com"} :method :options)]
             (is (= 403 status) response)))))))
 
 (deftest ^:parallel ^:integration-fast test-error-handling

          (is (pos? (get-in service ["service-description" "cpus"])) service)))
      (delete-service waiter-url service-id))))

; Marked explicit due to:
;   FAIL in (test-delete-app) (basic_test.clj:251)
; test-delete-app service-deleted-from-all-routers
; [CID=unknown] Expected status: 200, actual: 400
; Body:{"exception":["Read timed out",
; "java.net.SocketInputStream.socketRead0(Native Method)",
; "java.net.SocketInputStream.socketRead(SocketInputStream.java:116)"
; ...
; "marathonclj.rest.apps$delete_app.invoke(apps.clj:17)",
; "waiter.scheduler.marathon.MarathonScheduler$fn__18236.invoke(marathon.clj:260)",
; "waiter.scheduler$retry_on_transient_server_exceptions_fn$fn__17306.invoke(scheduler.clj:91)"
; ...
; "waiter.scheduler.marathon.MarathonScheduler.delete_app(marathon.clj:257)",
; "waiter.core$delete_app_handler.invokeStatic(core.clj:410)"
; ...
(deftest ^:parallel ^:integration-fast ^:explicit test-delete-app
  (testing-using-waiter-url
    "test-delete-app"
    (let [{:keys [service-id cookies]} (make-request-with-debug-info
                                         {:x-waiter-name (rand-name)}
                                         #(make-kitchen-request waiter-url %))]
      (testing "service-known-on-all-routers"
        (let [services (loop [routers (routers waiter-url)
                              services []]
                         (if-let [[_ router-url] (first routers)]
                           (recur (rest routers)
                                  (conj services
                                        (wait-for
                                          (fn []
                                            (let [{:keys [body]} (make-request router-url "/apps" :cookies cookies)
                                                  parsed-body (json/read-str body)]
                                              (first (filter #(= service-id (get % "service-id")) parsed-body))))
                                          :interval 2
                                          :timeout 30)))
                           services))]
          (is (every? #(and % (pos? (get-in % ["service-description" "cpus"]))) services)
              (str "Cannot find service: " service-id " in at least one router."))))

      (testing "service-deleted-from-all-routers"
        (let [{:keys [body] :as response} (make-request waiter-url (str "/apps/" service-id) :method :delete)]
          (assert-response-status response 200)
          (is body)
          (is (loop [routers (routers waiter-url)
                     result true]
                (if-let [[_ router-url] (first routers)]
                  (recur (rest routers)
                         (and result
                              (wait-for
                                (fn []
                                  (let [{:keys [body]} (make-request router-url "/apps" :cookies cookies)
                                        parsed-body (json/read-str body)]
                                    (empty? (filter #(= service-id (get % "service-id")) parsed-body))))
                                :interval 2
                                :timeout 30)))
                  result))
              (str "Service was not successfully deleted from the scheduler.")))))))

(deftest ^:parallel ^:integration-fast test-suspend-resume
  (testing-using-waiter-url

            [clojure.test :refer :all]
            [clojure.tools.logging :as log]
            [clojure.walk :as walk]
            [plumbing.core :as pc]
            [waiter.interstitial :as interstitial]
            [waiter.service-description :as sd]
            [waiter.util.client-tools :refer :all]
