Fix logging during Unit Tests