Skip to content

Commit d074565

Browse files
author
Vitor Hugo Salgado
committed
test: improve logger test
1 parent 53b17af commit d074565

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/utils/log/log.spec.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@ import Logger from '.'
22

33
describe('Log', function () {
44
it('should log', function () {
5+
const mock = jest.spyOn(console, 'error').mockImplementation()
6+
57
Logger.error('msg 1')
8+
9+
expect(mock).toBeCalledTimes(1)
10+
mock.mockRestore()
611
})
712
})

0 commit comments

Comments
 (0)