mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 18:36:30 +01:00 
			
		
		
		
	Merge pull request #1015 from TriliumNext/test_fix-flaky-getPlatformAppDataDir
test(data_dir): fix flaky getPlatformAppDataDir test on Windows
This commit is contained in:
		| @@ -77,6 +77,11 @@ describe("data_dir.ts unit tests", async () => { | |||||||
|             ["w/ darwin it should return '~/Library/Application Support'", ["darwin", undefined], "/Users/mock/Library/Application Support", "/Users/mock"] |             ["w/ darwin it should return '~/Library/Application Support'", ["darwin", undefined], "/Users/mock/Library/Application Support", "/Users/mock"] | ||||||
|         ]; |         ]; | ||||||
|  |  | ||||||
|  |         beforeEach(() => { | ||||||
|  |             // make sure OS does not set its own process.env.APPDATA, so that we can use our own supplied value | ||||||
|  |             delete process.env.APPDATA; | ||||||
|  |         }); | ||||||
|  |  | ||||||
|         testCases.forEach((testCase) => { |         testCases.forEach((testCase) => { | ||||||
|             const [testDescription, fnValues, expected, osHomedirMockValue] = testCase; |             const [testDescription, fnValues, expected, osHomedirMockValue] = testCase; | ||||||
|             return it(testDescription, () => { |             return it(testDescription, () => { | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user