Update expected error messages in test cases.