                   (is (= nil ((where nil) :zoooom!)))))
 
 (deftest default-kv
-         (let [r (ref nil)
+         (let [r (atom nil)
                s (default :service "foo" (register r))]
            (s {:service nil})
            (is (= {:service "foo"} (deref r)))

  (vec (map (fn [m] {:metric m}) metrics)))

(deftest combine-test
         (let [r (ref nil)
               sum (combine folds/sum (register r))
               min (combine folds/minimum (register r))
               max (combine folds/maximum (register r))

(defmacro run-stream
  "Applies inputs to stream, and returns outputs."
  [stream inputs]
  `(let [out# (atom [])
         stream# (~@stream (append out#))]
     (doseq [e# ~inputs] (stream# e#))
     (deref out#)))
