     test.isFalse @post, @post
 ]
 
-testAsyncMulti 'meteor-peerdb - errors for generated fields', [
+testAsyncMulti 'meteor-peerdb - exception while processing', [
   (test, expect) ->
     Log._intercept 3 if Meteor.isServer # Three to see if we catch more than expected
 
     IdentityGenerators.insert
-      source: 'foobar'
+      source: 'exception'
     ,
       expect (error, identityGeneratorId) =>
         test.isFalse error, error?.toString?() or error

  # Verify we are back to normal
  testDefinition test

Tinytest.add 'meteor-peerdb - invalid documents', (test) ->
  list = _.clone Document.Meta.list


        break if i.indexOf(@identityGeneratorId) isnt -1
      intercepted = EJSON.parse i

      test.isTrue intercepted.message.lastIndexOf('Exception processing PeerDB fields: Error: Test exception', 0) is 0
      test.equal intercepted.level, 'error'
]