diff --git a/docs/MockFunctionAPI.md b/docs/MockFunctionAPI.md index 6f4429054fba..5ffb11992b84 100644 --- a/docs/MockFunctionAPI.md +++ b/docs/MockFunctionAPI.md @@ -120,7 +120,7 @@ Clears all information stored in the [`mockFn.mock.calls`](#mockfnmockcalls), [` The [`clearMocks`](configuration#clearmocks-boolean) configuration option is available to clear mocks automatically before each tests. -:::info +:::warning Beware that `mockFn.mockClear()` will replace `mockFn.mock`, not just reset the values of its properties! You should, therefore, avoid assigning `mockFn.mock` to other variables, temporary or not, to make sure you don't access stale data.