diff --git a/package.json b/package.json index 0dfd0c3f..13d4964d 100644 --- a/package.json +++ b/package.json @@ -12,7 +12,7 @@ "build-release": "yarn build-package --minify", "test": "jest", "test-coverage": "jest --coverage", - "test-integration": "jest -c jest.config.integration.js", + "test-integration": "jest -c jest.config.integration.js && rm -rf src/tests/outputs", "format": "prettier --write '**/*.ts'", "format-check": "prettier --check '**/*.ts'", "lint": "eslint --ext .ts ./", diff --git a/src/tests/integration.test.ts b/src/tests/integration.test.ts index 48807502..c876e71b 100644 --- a/src/tests/integration.test.ts +++ b/src/tests/integration.test.ts @@ -15,13 +15,6 @@ let processStdoutMock: jest.SpyInstance let consoleLogMock: jest.SpyInstance let output = '' -function cleanupTest(path: string, ext: string): void { - ;['files', 'files_modified', 'files_added', 'files_removed'].forEach(type => { - unlinkSync(`${path}/${type}${ext}`) - }) - rmdirSync(path) -} - describe.each(p.testEvents)('Testing main.ts with %s event...', event => { /** * @function run @@ -80,13 +73,6 @@ describe.each(p.testEvents)('Testing main.ts with %s event...', event => { } }) afterEach(() => { - cleanupTest( - _resolve( - __dirname, - `outputs/${event}/${eventName}/o_${outputName}f_${fileOutputName}` - ), - fileOutputExpected - ) process.env = {...pEnv} output = '' jest.restoreAllMocks()