I tried making a mock for a logging handler, but to make it work with a logger I ended up patching so many things that having a class seem easier and more readable.