Skip to content

Commit 90467ea

Browse files
committed
test(text-helper): remove sinon -> jest for mock
1 parent c7af126 commit 90467ea

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

__tests__/tests/utilities/text-helper.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,18 @@
11
import { emojifyText, abbreviateNumber } from 'utils';
2-
import sinon from 'sinon';
32
import emoji from 'node-emoji';
43

54
describe('Text Helper', () => {
65
describe('emojifyText', () => {
76
it('should call correcly with text params', () => {
8-
const emojify = sinon.spy(emoji, 'emojify');
7+
const emojify = jest.spyOn(emoji, 'emojify');
98
const input = 'I need more :coffee';
109

1110
emojifyText(input);
1211

13-
expect(emojify.calledWith(input)).toEqual(true);
12+
expect(emojify).toBeCalledWith(input);
13+
14+
emojify.mockReset();
15+
emojify.mockRestore();
1416
});
1517
});
1618

0 commit comments

Comments
 (0)