Added error messages to unit tests