diff --git a/packages/core/src/test/shared/env/resolveEnv.test.ts b/packages/core/src/test/shared/env/resolveEnv.test.ts index 70d2032c223..02c4b00b3f1 100644 --- a/packages/core/src/test/shared/env/resolveEnv.test.ts +++ b/packages/core/src/test/shared/env/resolveEnv.test.ts @@ -10,10 +10,8 @@ import path from 'path' describe('resolveEnv', async function () { let sandbox: sinon.SinonSandbox - let originalPlatform = process.platform beforeEach(function () { sandbox = sinon.createSandbox() - sandbox.stub(process, 'platform').value('win32') }) afterEach(function () { @@ -57,7 +55,7 @@ describe('resolveEnv', async function () { describe('resolveUnix', async function () { const originalEnv = { ...process.env } // skip mac test on windows - if (originalPlatform !== 'win32') { + if (process.platform !== 'win32') { it('mergeResolvedShellPath should get path on mac/unix', async function () { sandbox.stub(process.env, 'PATH').value('') // stub the resolve Env logic cause this is platform sensitive.