       done()
     .fail (error) =>
       @logger.error error
-      done(error)
+      done(JSON.stringify(error))
 
   afterEach (done) ->
     @client.states.byId(@state.id).delete(@state.version)

      done()
    .fail (error) =>
      @logger.error error
      done(error)

  it 'should create some states and use them as transitions references', (done) ->
    Q.all _.map [1..101], => @client.states.save(newState())

        done()
    .fail (error) =>
      @logger.error error
      done(JSON.stringify(error))

