         modifiedHandler.reset()
         buffer.save()
 
-        expect(fs.existsSync(filePath)).toBeTruthy()
+        expect(existsSync(filePath)).toBeTruthy()
         expect(modifiedHandler).toHaveBeenCalledWith(false)
         expect(buffer.isModified()).toBe false
 

      it "saves the contents of the buffer to the path", ->
        saveBuffer.setText 'Buffer contents!'
        saveBuffer.save()
        expect(fs.readFileSync(filePath, 'utf8')).toEqual 'Buffer contents!'

      it "fires will-be-saved and saved events around the call to fs.writeFileSync", ->
        events = []
        beforeSave1 = -> events.push('beforeSave1')
        beforeSave2 = -> events.push('beforeSave2')


        removeHandler = jasmine.createSpy('removeHandler')
        bufferToDelete.file.on 'removed', removeHandler
        removeSync(filePath)
        waitsFor "file to be removed", ->
          removeHandler.callCount > 0

