Skip to content

Commit

Permalink
Fix sample code of mock class constructors (#4115)
Browse files Browse the repository at this point in the history
  • Loading branch information
murajun1978 authored and cpojer committed Jul 25, 2017
1 parent 13e375d commit ffd43f7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions docs/en/MockFunctionAPI.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ module.exports = class SomeClass {
}
// OtherModule.test.js
jest.mock('SomeClass')
const SomeClass = require('SomeClass')
const mMock = jest.fn()
SomeClass.mockImplementation(() => {
Expand Down

0 comments on commit ffd43f7

Please sign in to comment.