diff --git a/googlemock/test/gmock_output_test.py b/googlemock/test/gmock_output_test.py index 6b4ab901..d7c3f27e 100755 --- a/googlemock/test/gmock_output_test.py +++ b/googlemock/test/gmock_output_test.py @@ -159,6 +159,9 @@ class GMockOutputTest(gmock_test_utils.TestCase): golden_file = open(GOLDEN_PATH, 'rb') golden = golden_file.read().decode('utf-8') golden_file.close() + # On Windows the repository might have been checked out with \r\n line + # endings, so normalize it here. + golden = ToUnixLineEnding(golden) # The normalized output should match the golden file. self.assertEqual(golden, output)