Refactored MessageFormaterTests to remove repetition.