diff test/test_admin.py @ 7586:859c57bc8d91

test: limit search for \r to first 100 bytes. Don't scan entire file. just look at 100 bytes which should include all of the first line.
author John Rouillard <rouilj@ieee.org>
date Mon, 24 Jul 2023 21:24:07 -0400
parents 227aca44fea5
children 4de48eadf5f4
line wrap: on
line diff
--- a/test/test_admin.py	Mon Jul 24 21:16:41 2023 -0400
+++ b/test/test_admin.py	Mon Jul 24 21:24:07 2023 -0400
@@ -64,7 +64,7 @@
 
     try:
         # handle text files with \r\n line endings
-        contents.index("\r")
+        contents.index("\r", 0, 100)
         contents = contents.replace("\r\n", "\n")
     except ValueError:
         pass

Roundup Issue Tracker: http://roundup-tracker.org/