   ([active-topos hb-topos error-topos bp-topos]
     (mock-cluster-state active-topos hb-topos error-topos bp-topos nil))
   ([active-topos hb-topos error-topos bp-topos wt-topos]
-    (reify IStormClusterState
-      (teardownHeartbeats [this id] (teardown-heartbeats id))
-      (teardownTopologyErrors [this id] (teardown-topo-errors id))
-      (removeBackpressure [this id] (teardown-backpressure-dirs id))
-      (removeAllPrivateWorkerKeys [this id] (teardown-wt-dirs id))
-      (activeStorms [this] active-topos)
-      (heartbeatStorms [this] hb-topos)
-      (errorTopologies [this] error-topos)
-      (backpressureTopologies [this] bp-topos)
-      (idsOfTopologiesWithPrivateWorkerKeys [this] (into #{} wt-topos)))))
+    (let [cluster-state (Mockito/mock IStormClusterState)]
+      (.thenReturn (Mockito/when (.activeStorms cluster-state)) active-topos)
+      (.thenReturn (Mockito/when (.heartbeatStorms cluster-state)) hb-topos)
+      (.thenReturn (Mockito/when (.errorTopologies cluster-state)) error-topos)
+      (.thenReturn (Mockito/when (.backpressureTopologies cluster-state)) bp-topos)
+      (.thenReturn (Mockito/when (.idsOfTopologiesWithPrivateWorkerKeys cluster-state)) (into #{} wt-topos))
+      cluster-state)))
 
 (deftest cleanup-storm-ids-returns-inactive-topos
          (let [mock-state (mock-cluster-state (list "topo1") (list "topo1" "topo2" "topo3"))

        (.setLogConfig nimbus "foo" mock-config)
        (.setTopologyLogConfig (Mockito/verify cluster-state) (Mockito/any String) (Mockito/eq expected-config) (Mockito/any Map))))))

(defn teardown-heartbeats [id])
(defn teardown-topo-errors [id])
(defn teardown-backpressure-dirs [id])
(defn teardown-wt-dirs [id])

(defn mock-cluster-state
  ([]
    (mock-cluster-state nil nil))

          (.rmDependencyJarsInTopology (Mockito/verify nimbus) "topo3")

          ;; remove topos from heartbeat cache
          (is (= (count (.get (.getHeartbeatsCache nimbus))) 0))))))


(deftest do-cleanup-does-not-teardown-active-topos
