diff --git a/__tests__/buildx/bake.test.itg.ts b/__tests__/buildx/bake.test.itg.ts index c9b900d..f4499f2 100644 --- a/__tests__/buildx/bake.test.itg.ts +++ b/__tests__/buildx/bake.test.itg.ts @@ -14,7 +14,7 @@ * limitations under the License. */ -import {beforeEach, describe, expect, jest, test} from '@jest/globals'; +import {describe, expect, test} from '@jest/globals'; import * as fs from 'fs'; import * as path from 'path'; @@ -25,10 +25,6 @@ const fixturesDir = path.join(__dirname, '..', 'fixtures'); const maybe = !process.env.GITHUB_ACTIONS || (process.env.GITHUB_ACTIONS === 'true' && process.env.ImageOS && process.env.ImageOS.startsWith('ubuntu')) ? describe : describe.skip; -beforeEach(() => { - jest.clearAllMocks(); -}); - maybe('getDefinition', () => { // prettier-ignore test.each([ diff --git a/__tests__/buildx/history.test.itg.ts b/__tests__/buildx/history.test.itg.ts index 009056b..78188c3 100644 --- a/__tests__/buildx/history.test.itg.ts +++ b/__tests__/buildx/history.test.itg.ts @@ -14,7 +14,7 @@ * limitations under the License. */ -import {beforeEach, describe, expect, jest, test} from '@jest/globals'; +import {describe, expect, test} from '@jest/globals'; import * as fs from 'fs'; import * as path from 'path'; @@ -31,10 +31,6 @@ const tmpDir = path.join(process.env.TEMP || '/tmp', 'buildx-history-jest'); const maybe = !process.env.GITHUB_ACTIONS || (process.env.GITHUB_ACTIONS === 'true' && process.env.ImageOS && process.env.ImageOS.startsWith('ubuntu')) ? describe : describe.skip; -beforeEach(() => { - jest.clearAllMocks(); -}); - maybe('exportBuild', () => { // prettier-ignore test.each([ diff --git a/__tests__/github.test.itg.ts b/__tests__/github.test.itg.ts index 852e0a6..2163a76 100644 --- a/__tests__/github.test.itg.ts +++ b/__tests__/github.test.itg.ts @@ -14,7 +14,7 @@ * limitations under the License. */ -import {beforeEach, describe, expect, it, jest, test} from '@jest/globals'; +import {describe, expect, it, test} from '@jest/globals'; import fs from 'fs'; import * as path from 'path'; @@ -32,10 +32,6 @@ const tmpDir = path.join(process.env.TEMP || '/tmp', 'github-jest'); const maybe = !process.env.GITHUB_ACTIONS || (process.env.GITHUB_ACTIONS === 'true' && process.env.ImageOS && process.env.ImageOS.startsWith('ubuntu')) ? describe : describe.skip; -beforeEach(() => { - jest.clearAllMocks(); -}); - maybe('uploadArtifact', () => { it('uploads an artifact', async () => { const res = await GitHub.uploadArtifact({ diff --git a/jest.config.itg.ts b/jest.config.itg.ts index 9628c49..0e1365e 100644 --- a/jest.config.itg.ts +++ b/jest.config.itg.ts @@ -33,7 +33,6 @@ process.env = Object.assign({}, process.env, { }; module.exports = { - clearMocks: true, testEnvironment: 'node', moduleFileExtensions: ['js', 'ts'], setupFiles: ['dotenv/config'],