diff --git a/packages/artifact/__tests__/download-artifact.test.ts b/packages/artifact/__tests__/download-artifact.test.ts index 7d8fead5..574f6b15 100644 --- a/packages/artifact/__tests__/download-artifact.test.ts +++ b/packages/artifact/__tests__/download-artifact.test.ts @@ -13,7 +13,7 @@ import { streamExtractExternal } from '../src/internal/download/download-artifact' import {getUserAgentString} from '../src/internal/shared/user-agent' -//import {noopLogs} from './common' +import {noopLogs} from './common' import * as config from '../src/internal/shared/config' import {ArtifactServiceClientJSON} from '../src/generated' import * as util from '../src/internal/shared/util' @@ -89,7 +89,7 @@ const expectExtractedArchive = async (dir: string): Promise => { } const setup = async (): Promise => { - //noopLogs() + noopLogs() await fs.promises.mkdir(testDir, {recursive: true}) await createTestArchive() diff --git a/packages/artifact/src/internal/download/download-artifact.ts b/packages/artifact/src/internal/download/download-artifact.ts index 995dbafb..a06dcf28 100644 --- a/packages/artifact/src/internal/download/download-artifact.ts +++ b/packages/artifact/src/internal/download/download-artifact.ts @@ -97,7 +97,7 @@ export async function streamExtractExternal( core.debug(`Extracting artifact entry: ${fullPath}`) entry.pipe(createWriteStream(fullPath)) }) - .on('close', () => { + .on('end', () => { clearTimeout(timer) resolve() })