 
   customer = id: 'customer_123', name: 'Dominik'
   registration = id: 'registration_123'
+  sharedCommitCollection = new Mongo.Collection('messaging_shared_commits')
 
   beforeEach ->
-    @app = new CustomerApp Configuration: { appId: 'CustomerApp' }
-    @app.start()
-
-  afterEach ->
-    @app.reset()
-
-  it 'handles messages within one app correctly', (test, done) ->
-
-    @app.given(
-      new CustomerApp.RegisterCustomer {
-        targetId: registration.id
-        customerId: customer.id
-        customerName: customer.name
-      }
-    )
-    .expect([
+    @fakeDates = sinon.useFakeTimers('Date')
+    @app = new CustomerApp Configuration: {
+      appId: 'CustomerApp'
+      eventSourcing: { commitsCollection: sharedCommitCollection }
+    }
+    @generatedEventsForCustomerRegistration = [
       new CustomerApp.RegistrationInitiated({
         sourceId: registration.id
         version: 1

        version: 3
        timestamp: new Date()
      })
    ])
    .run(done)

        timestamp: new Date()
        customerId: customer.id
      })
      # This is just visible in the app that runs the code
      # since it is directly published via the event store
      # instead of saved to the DB as part of a commit!
      new CustomerApp.WelcomeEmailSent({
        sourceId: '999'
        version: 1
