test for Message.get_messages