 
 "To demonstrate how it works we will mock a database that stores all the received events into into an `atom`."
 (fact
+ :integ
  (def stored-events (atom [])))
 
 "We mock a module function to provide our mock `database-event-storage-chan`.
 It takes tuples `[event ack]`, where `event` is an event (map) to be stored 
 and `ack` is a channel to be closed once the event is stored."
 (fact
+ :integ
  (defn mock-db-storage-module [$]
    (di/provide $ database-event-storage-chan [foo]
                (let [database-event-storage-chan (async/chan)]


"We wish to see that after we post and consume all events (which need to be the same events), all events are acknowledged."
(fact
 (let [event (fn [u1 u2] {:kind :fact
                          :name "test/follows"
                          :key u1

"To demonstrate how it works we will mock the `publish` function.
Our mock will add each published event to the `published-events` atom."
(fact
 :integ
 (def published-events (atom [])))

"The following mock module provides our mock `publish`."
(fact
 :integ
 (defn mock-publish-module [$]
   (di/provide $ publish [foo]
               (fn [ev]
