Added unit test for message viewer