diff --git a/CHANGELOG.md b/CHANGELOG.md index 5e632c6e6ac3..3bc2c8d7bb91 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -18,6 +18,7 @@ - `[jest-jasmine2]` Refine typings of `queueRunner` ([#10215](https://github.com/facebook/jest/pull/10215)) - `[jest-jasmine2]` Remove usage of `Function` type ([#10216](https://github.com/facebook/jest/pull/10216)) - `[jest-resolve]` Improve types ([#10239](https://github.com/facebook/jest/pull/10239)) +- `[docs]` Clarify the [`jest.requireActual(moduleName)`](https://jestjs.io/docs/en/jest-object#jestrequireactualmodulename) example ### Performance diff --git a/docs/JestObjectAPI.md b/docs/JestObjectAPI.md index d1205b6768d7..03b670ba8177 100644 --- a/docs/JestObjectAPI.md +++ b/docs/JestObjectAPI.md @@ -387,7 +387,7 @@ Example: ```js jest.mock('../myModule', () => { // Require the original module to not be mocked... - const originalModule = jest.requireActual(moduleName); + const originalModule = jest.requireActual('../myModule'); return { __esModule: true, // Use it when dealing with esModules