docker-attest-build-provenance/__tests__/index.test.ts
Eugene 9b4b35feaa
unit test (#13)
* test

* updated
2024-02-29 17:04:03 -08:00

18 lines
414 B
TypeScript

/**
* Unit tests for the action's entrypoint, src/index.ts
*/
import * as main from '../src/main'
// Mock the action's entrypoint
const runMock = jest.spyOn(main, 'run').mockImplementation()
describe('index', () => {
it('calls run when imported', async () => {
// eslint-disable-next-line @typescript-eslint/no-require-imports
require('../src/index')
expect(runMock).toHaveBeenCalled()
})
})