Add test code for `logging`