1
0
Fork 0
toolkit/packages/artifact/__tests__/common.ts

10 lines
411 B
TypeScript
Raw Normal View History

2023-12-01 00:31:27 +00:00
import * as core from '@actions/core'
// noopLogs mocks the console.log and core.* functions to prevent output in the console while testing
export const noopLogs = (): void => {
jest.spyOn(console, 'log').mockImplementation(() => {})
2023-12-01 00:31:27 +00:00
jest.spyOn(core, 'debug').mockImplementation(() => {})
jest.spyOn(core, 'info').mockImplementation(() => {})
jest.spyOn(core, 'warning').mockImplementation(() => {})
}