Fix logger test
Created by: Dreamlone
Now the test_logger_write_logs_correctly checks not for the last recorded message, but for the fact that there is a message in the logs In the future, you may need to figure out why the logger sometimes returns messages in the wrong order