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.
1 parent bdb3b0a commit ec25eeaCopy full SHA for ec25eea
docs/gmock_cook_book.md
@@ -285,6 +285,10 @@ If you are concerned about the performance overhead incurred by virtual
285
functions, and profiling confirms your concern, you can combine this with the
286
recipe for [mocking non-virtual methods](#MockingNonVirtualMethods).
287
288
+Alternatively, instead of introducing a new interface, you can rewrite your code
289
+to accept a std::function instead of the free function, and then use
290
+[MockFunction](#MockFunction) to mock the std::function.
291
+
292
### Old-Style `MOCK_METHODn` Macros
293
294
Before the generic `MOCK_METHOD` macro
0 commit comments