Set level of some debug messages to LOG_DEBUG
Add a test for logging