setup-hugo/__tests__/index.test.ts
Peter Kurfer 034dd15f69
All checks were successful
Check Transpiled JavaScript / Check dist/ (push) Successful in 31s
Continuous Integration / GitHub Actions Test (push) Successful in 9s
Continuous Integration / TypeScript Tests (push) Successful in 47s
feat: use cache
2024-05-03 16:17:32 +02:00

17 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()
})
})