   `((ctrl-flow/in-parallel do-stuff do-stuff)))
 
 (def pipeline-with-substeps-state
-  (let [joda-date-12 (DateTime. 2016 01 01 12 00 (DateTimeZone/UTC))
-        joda-date-14 (DateTime. 2016 01 01 14 00 (DateTimeZone/UTC))]
-    {'(1)   {:status                :running
-             :first-updated-at      joda-date-12
-             :most-recent-update-at joda-date-14
-             }
-     '(1 1) {:status                :running
-             :first-updated-at      joda-date-12
-             :most-recent-update-at joda-date-14
-             }}))
+  {'(1)   {:status                :running
+           :first-updated-at      joda-date-12
+           :most-recent-update-at joda-date-14
+           }
+   '(1 1) {:status                :running
+           :first-updated-at      joda-date-12
+           :most-recent-update-at joda-date-14
+           }})
 
 (defn foo-pipeline-build-state [status]
-  (let [joda-date-12 (DateTime. 2016 01 01 12 00 (DateTimeZone/UTC))
-        joda-date-14 (DateTime. 2016 01 01 14 00 (DateTimeZone/UTC))]
-    {'(1) {:status                status
-           :first-updated-at      joda-date-12
-           :most-recent-update-at joda-date-14}}))
+  {'(1) {:status                status
+         :first-updated-at      joda-date-12
+         :most-recent-update-at joda-date-14}})
+
+(defn pipeline-build-state-with-trigger [status]
+  {'(1) {:status                status
+         :first-updated-at      joda-date-12
+         :most-recent-update-at joda-date-14
+         :type                  :manual-trigger
+         }})
+
 
 
 (deftest build-details-from-pipeline-test

            )
  (:import (org.joda.time DateTime DateTimeZone)))

(defn do-stuff [] {})

(def foo-pipeline

    (let [

          event-channel (async/chan)
          sent-channel (async/chan 1)
          closed (atom false)
          ws-ch (reify httpkit-server/Channel
                  (on-close [& _])
                  (close [ws-ch] (reset! closed true))
                  (send! [ws-ch data] (async/>!! sent-channel data)))]
      (with-redefs [event-bus/subscribe (fn [ctx topic] nil)
                    event-bus/only-payload (fn [subscription] event-channel)
                    state/get-all (fn [_] {})]
