   "NOTE: as of 0.0.12, clj-redis has no pipeline facility."
   [{:keys [test-key test-val] :as opts}]
   (println "Benching clj-redis...")
-  (let [db (clj-redis/init)]
-    (time-threaded-laps
-     opts
+  (time-threaded-laps
+   opts
+   (let [db (clj-redis/init)]
      ;; SET (unpipelined)
      (clj-redis/ping db)
      (clj-redis/set  db test-key test-val)

       (carmine/get test-key)
       (carmine/ping)))))

(defn- sorted-map-by-val
  [m]
  (into (sorted-map-by #(compare (get m %1) (get m %2))) m))

(defn bench-and-compare-clients
  [opts]

    (println "Done!" "\n")
    (println "Raw times:" times "\n")
    (println "Sorted relative times (smaller is better):"
             (sorted-map-by-vals times))))

(comment

  ;; Easy test
  (bench-and-compare-clients (make-benching-options :num-threads 1
                                                    :num-laps 10))

  ;; Standard test
  (bench-and-compare-clients (make-benching-options))
