import { TaskHasher, HasherContext } from '@nx/devkit';

import { <%=propertyName%>Hasher } from './hasher';

describe('<%=propertyName%>Hasher', () => {
    it('should generate hash', async () => {
        const mockHasher: TaskHasher = {
            hashTask: jest.fn().mockReturnValue({value: 'hashed-task'})
        } as unknown as TaskHasher
        const hash = await <%=propertyName%>Hasher({
            id: 'my-task-id',
            target: {
                project: 'proj',
                target: 'target'
            },
            overrides: {}
        }, {
            hasher: mockHasher
        } as unknown as HasherContext)
        expect(hash).toEqual({value: 'hashed-task'})
    })
})
