We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
restoring
resetting
1 parent dc736d6 commit d8f5d9dCopy full SHA for d8f5d9d
docs/api/mock.md
@@ -170,8 +170,8 @@ await asyncMock() // throws "Async error"
170
Does what `mockClear` does and resets inner implementation to the original function.
171
This also resets all "once" implementations.
172
173
-Note that restoring a mock from `vi.fn()` will set implementation to an empty function that returns `undefined`.
174
-Restoring a mock from `vi.fn(impl)` will restore implementation to `impl`.
+Note that resetting a mock from `vi.fn()` will set implementation to an empty function that returns `undefined`.
+resetting a mock from `vi.fn(impl)` will restore implementation to `impl`.
175
176
This is useful when you want to reset a mock to its original state.
177
0 commit comments