added unit tests for logging

To make sure logging works as expected, I added a few unit tests. Those should also serve as an example on how to do unit tests with gtest.

(The change from EXPECT to ASSERT is because only ASSERT is fatal)