From 213757cd5b1ca86f86092c7df5add660b92c62d4 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 24 Feb 2021 19:20:55 +0100 Subject: [PATCH] fix #114031 --- src/vs/platform/storage/test/browser/storageService.test.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/vs/platform/storage/test/browser/storageService.test.ts b/src/vs/platform/storage/test/browser/storageService.test.ts index f3e92ff08805f..29b53c113e83b 100644 --- a/src/vs/platform/storage/test/browser/storageService.test.ts +++ b/src/vs/platform/storage/test/browser/storageService.test.ts @@ -18,6 +18,7 @@ import { IEnvironmentService } from 'vs/platform/environment/common/environment' suite('StorageService (browser)', function () { const disposables = new DisposableStore(); + let storageService: BrowserStorageService; createSuite({ setup: async () => { @@ -28,13 +29,14 @@ suite('StorageService (browser)', function () { const userDataProvider = disposables.add(new InMemoryFileSystemProvider()); disposables.add(fileService.registerProvider(Schemas.userData, userDataProvider)); - const storageService = disposables.add(new BrowserStorageService({ id: String(Date.now()) }, { userRoamingDataHome: URI.file('/User').with({ scheme: Schemas.userData }) } as unknown as IEnvironmentService, fileService)); + storageService = disposables.add(new BrowserStorageService({ id: String(Date.now()) }, { userRoamingDataHome: URI.file('/User').with({ scheme: Schemas.userData }) } as unknown as IEnvironmentService, fileService)); await storageService.initialize(); return storageService; }, teardown: async storage => { + await storageService.flush(); disposables.clear(); } });