From e9218d10889cd89b4dc13a7ea772d84a032d1bef Mon Sep 17 00:00:00 2001 From: ehhc Date: Thu, 10 May 2018 22:39:00 +0200 Subject: [PATCH] Fix for the broken test --- tests/dataApi/attachmentManagement.test.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/dataApi/attachmentManagement.test.js b/tests/dataApi/attachmentManagement.test.js index 148f6958..734aa3b9 100644 --- a/tests/dataApi/attachmentManagement.test.js +++ b/tests/dataApi/attachmentManagement.test.js @@ -267,10 +267,10 @@ it('should delete the correct attachment folder if a note is deleted', function const storageKey = 'storageKey' const noteKey = 'noteKey' findStorage.findStorage = jest.fn(() => dummyStorage) - sander.rimraf = jest.fn() + sander.rimrafSync = jest.fn() const expectedPathToBeDeleted = path.join(dummyStorage.path, systemUnderTest.DESTINATION_FOLDER, noteKey) systemUnderTest.deleteAttachmentFolder(storageKey, noteKey) expect(findStorage.findStorage).toHaveBeenCalledWith(storageKey) - expect(sander.rimraf).toHaveBeenCalledWith(expectedPathToBeDeleted) + expect(sander.rimrafSync).toHaveBeenCalledWith(expectedPathToBeDeleted) })