The following code gets wrongly autofixed by the jest/spy-on rule:
foo[bar] = jest.fn().mockReturnValue(undefined)
Actual behavior:
jest.spyOn(foo, 'bar').mockImplementation().mockReturnValue(undefined)
Expected behavior:
jest.spyOn(foo, bar).mockImplementation().mockReturnValue(undefined)
The following code gets wrongly autofixed by the
jest/spy-onrule:Actual behavior:
Expected behavior: