From a097c8bd17776148acf7fb643698fab1e9685027 Mon Sep 17 00:00:00 2001 From: Matt Seddon Date: Thu, 27 Apr 2023 15:17:06 +1000 Subject: [PATCH] self review --- extension/src/test/suite/setup/util.ts | 2 -- extension/src/util/appdirs.test.ts | 8 ++++---- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/extension/src/test/suite/setup/util.ts b/extension/src/test/suite/setup/util.ts index d72d277b4c..c0be6298fc 100644 --- a/extension/src/test/suite/setup/util.ts +++ b/extension/src/test/suite/setup/util.ts @@ -33,7 +33,6 @@ export const buildSetup = ( messageSpy, resourceLocator, internalCommands, - dvcExecutor, dvcReader, gitExecutor, gitReader @@ -99,7 +98,6 @@ export const buildSetup = ( return { config, - dvcExecutor, internalCommands, messageSpy, mockAutoInstallDvc, diff --git a/extension/src/util/appdirs.test.ts b/extension/src/util/appdirs.test.ts index d47f80f1bb..a536d2cbc7 100644 --- a/extension/src/util/appdirs.test.ts +++ b/extension/src/util/appdirs.test.ts @@ -2,14 +2,14 @@ import { join } from 'path' import { getDVCAppDir, getIterativeAppDir } from './appdirs' import { getProcessPlatform } from '../env' -const mockedUserConfigDir = require('appdirs').userConfigDir -const mockedGetProcessPlatform = jest.mocked(getProcessPlatform) -const mockedJoin = jest.mocked(join) - jest.mock('appdirs', () => ({ userConfigDir: jest.fn() })) jest.mock('../env') jest.mock('path') +const mockedUserConfigDir = require('appdirs').userConfigDir +const mockedGetProcessPlatform = jest.mocked(getProcessPlatform) +const mockedJoin = jest.mocked(join) + beforeEach(() => { jest.resetAllMocks() })