From 88cfea0062f7d6ea26171a5ad26259ce1c3fd3d2 Mon Sep 17 00:00:00 2001 From: Simen Bekkhus Date: Thu, 1 Apr 2021 12:12:59 +0200 Subject: [PATCH] normalize is async now --- packages/jest-config/src/__tests__/normalize.test.ts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/jest-config/src/__tests__/normalize.test.ts b/packages/jest-config/src/__tests__/normalize.test.ts index f3530f502f70..1000d1e10c14 100644 --- a/packages/jest-config/src/__tests__/normalize.test.ts +++ b/packages/jest-config/src/__tests__/normalize.test.ts @@ -1844,19 +1844,19 @@ describe('extensionsToTreatAsEsm', () => { }); describe('haste.enableSymlinks', () => { - it('should throw if watchman is not disabled', () => { - expect(() => + it('should throw if watchman is not disabled', async () => { + await expect( normalize({haste: {enableSymlinks: true}, rootDir: '/root/'}, {}), - ).toThrow('haste.enableSymlinks is incompatible with watchman'); + ).rejects.toThrow('haste.enableSymlinks is incompatible with watchman'); - expect(() => + await expect( normalize( {haste: {enableSymlinks: true}, rootDir: '/root/', watchman: true}, {}, ), - ).toThrow('haste.enableSymlinks is incompatible with watchman'); + ).rejects.toThrow('haste.enableSymlinks is incompatible with watchman'); - const {options} = normalize( + const {options} = await normalize( {haste: {enableSymlinks: true}, rootDir: '/root/', watchman: false}, {}, );