       afterEach ->
         if fs.existsSync(newPath)
           fs.removeSync(newPath)
-          removeHandler = jasmine.createSpy('removeHandler')
-          file.on 'removed', removeHandler
-          waitsFor "remove event", 30000, -> removeHandler.callCount > 0
+          deleteHandler = jasmine.createSpy('deleteHandler')
+          file.onDidDelete(deleteHandler)
+          waitsFor "remove event", 30000, -> deleteHandler.callCount > 0
 
       it "it updates its path", ->
         moveHandler = jasmine.createSpy('moveHandler')

      file.readSync()

    describe "when the contents of the file change", ->
      it "triggers 'contents-changed' event handlers", ->
        changeHandler = jasmine.createSpy('changeHandler')
        file.on 'contents-changed', changeHandler
        fs.writeFileSync(file.getPath(), "this is new!")

        waitsFor "change event", ->

    describe "when a file is deleted and the recreated within a small amount of time (git sometimes does this)", ->
      it "triggers a contents change event if the contents change", ->
        changeHandler = jasmine.createSpy("file changed")
        deleteHandler = jasmine.createSpy("file deleted")
        file.onDidChange changeHandler
        file.onDidDelete deleteHandler

        expect(changeHandler).not.toHaveBeenCalled()

