Stub logger output in tests