skovhus / jest-codemods

Codemods for migrating to Jest https://github.com/facebook/jest 👾
MIT License
878 stars 81 forks source link

jasmine *.calls.reset() should be replaced by *.mockReset() #602

Closed jase88 closed 2 weeks ago

jase88 commented 3 weeks ago

jasmine has a namespace calls on spies with a method called reset() , see their docs.

Desired behaviour

Input:

mySpy.calls.reset();

should be transformed to:

mySpy.mockReset();