setup-hugo/__tests__/index.test.ts
Peter Kurfer 2fc1d51eb6
Some checks failed
Continuous Integration / TypeScript Tests (push) Failing after 38s
Continuous Integration / GitHub Actions Test (push) Failing after 7s
Check Transpiled JavaScript / Check dist/ (push) Successful in 1m29s
feat: initial version
2024-05-02 18:38:23 +02:00

17 lines
417 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.ts')
expect(runMock).toHaveBeenCalled()
})
})