     describe "#removeDocumentsOf", ->
 
         describe "When removeDocumentsOf is called with an object as parameter", ->
+
+            before (done) -> fixtures.resetDatabase
+                                removeAllViews: true
+                                callback: done
+
             before (done) -> fixtures.load doctypeTarget: 'Alarm', callback: done
 
             it "There should be an error", (done) ->

                @stub.called.should.be.true

        describe "When Data System fails at sending doctypes list", (done) ->
            before ->
                @sandbox = sinon.sandbox.create()
                @stub = @sandbox.stub fixtures, "removeDocumentsOf"

                    done()

        describe "When _addDoc is called with a document with a field _attachments", ->
            before (done) -> fixtures.resetDatabase
                                removeAllViews: true
                                callback: done
            before (done) ->
                @doc = require('./fixtures/fixtures-with-attachment.json')[0]
                @attachment = @doc._attachments
