fix issues w.r.t. logging in tests

@stdweird: pls review