Have you ever mocked your logger in a test, or wished you could? That is something like
Have you ever mocked your logger in a test, or wished you could? That is something like
Have you ever mocked your logger in a test, or wished you could? That is something like
TEST(some test name)
mockLogger logger
logger.expect_call(log("some string"))
DoSomething(logger)
You're viewing a single thread.
All Comments
5 comments
Why would you want to mock a logger? Aren't the different Log Levels already enough?
0 0 Reply@DmMacniel so you can prove some interesting thing is really logged? maybe someone else has a different reason.
1 0 Reply