fix
This commit is contained in:
@@ -154,7 +154,10 @@ describe('action', () => {
|
|||||||
return ''
|
return ''
|
||||||
})
|
})
|
||||||
|
|
||||||
isDirectoryMock.mockImplementation(() => true)
|
// isDirectoryMock.mockImplementation(() => true)
|
||||||
|
getConsolidatedDirectoryMock.mockImplementation(() => {
|
||||||
|
return { consolidatedDirectory: '/tmp/test', needToCleanUpDir: false }
|
||||||
|
})
|
||||||
isActionRepoMock.mockImplementation(() => true)
|
isActionRepoMock.mockImplementation(() => true)
|
||||||
|
|
||||||
createTempDirMock.mockImplementation(() => '/tmp/test')
|
createTempDirMock.mockImplementation(() => '/tmp/test')
|
||||||
@@ -167,7 +170,7 @@ describe('action', () => {
|
|||||||
await main.run('directory')
|
await main.run('directory')
|
||||||
|
|
||||||
// Check the results
|
// Check the results
|
||||||
expect(isDirectoryMock).toHaveBeenCalledWith('directory')
|
expect(getConsolidatedDirectoryMock).toHaveBeenCalledTimes(1)
|
||||||
expect(setFailedMock).toHaveBeenCalledWith('Something went wrong')
|
expect(setFailedMock).toHaveBeenCalledWith('Something went wrong')
|
||||||
|
|
||||||
// Expect the files to be cleaned up
|
// Expect the files to be cleaned up
|
||||||
|
|||||||
Reference in New Issue
Block a user