Skip to content

Commit 681948c

Browse files
committed
CI fix: windows line endings bring joy
1 parent 4c838a2 commit 681948c

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Lib/test/test_traceback_timestamps/test_basic.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,8 @@ def test_strip_removes_timestamps(self):
192192
"-X", f"traceback_timestamps={mode}",
193193
"-c", self.STRIP_SCRIPT,
194194
)
195-
parts = result.out.decode().split("---MARKER---\n")
195+
output = result.out.decode().replace('\r\n', '\n')
196+
parts = output.split("---MARKER---\n")
196197
raw, stripped = parts[0], parts[1]
197198
self.assertIn("<@", raw)
198199
self.assertNotIn("<@", stripped)
@@ -203,7 +204,8 @@ def test_strip_noop_when_disabled(self):
203204
result = script_helper.assert_python_ok(
204205
"-X", "traceback_timestamps=0", "-c", self.STRIP_SCRIPT,
205206
)
206-
parts = result.out.decode().split("---MARKER---\n")
207+
output = result.out.decode().replace('\r\n', '\n')
208+
parts = output.split("---MARKER---\n")
207209
raw, stripped = parts[0], parts[1]
208210
self.assertEqual(raw, stripped)
209211

0 commit comments

Comments
 (0)