Skip to content

Commit b6fd364

Browse files
committed
test(Transition): Use jest.fn instead of sinon
1 parent c12a5f2 commit b6fd364

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

test/Transition-test.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -472,9 +472,9 @@ describe('Transition', () => {
472472

473473
describe('findDOMNode', () => {
474474
it('uses ReactDOM.findDOMNode by default', done => {
475-
const expectDiv = sinon.spy(node => expect(node.nodeName).toEqual('DIV'));
475+
const expectDiv = jest.fn(node => expect(node.nodeName).toEqual('DIV'));
476476
const handleExited = () => {
477-
expect(expectDiv.called).toBe(true);
477+
expect(expectDiv).toHaveBeenCalled()
478478

479479
done();
480480
}
@@ -514,9 +514,9 @@ describe('Transition', () => {
514514
}
515515
}
516516

517-
const expectSpan = sinon.spy(node => expect(node.nodeName).toEqual('SPAN'));
517+
const expectSpan = jest.fn(node => expect(node.nodeName).toEqual('SPAN'));
518518
const handleExited = () => {
519-
expect(expectSpan.called).toBe(true);
519+
expect(expectSpan).toHaveBeenCalledWith();
520520

521521
done();
522522
}

0 commit comments

Comments
 (0)