[Python-checkins] cpython: Issue #25122: optimize test_eintr

victor.stinner python-checkins at python.org
Wed Sep 16 00:01:56 CEST 2015


https://hg.python.org/cpython/rev/5388fa98f7a3
changeset:   98018:5388fa98f7a3
user:        Victor Stinner <victor.stinner at gmail.com>
date:        Tue Sep 15 23:59:00 2015 +0200
summary:
  Issue #25122: optimize test_eintr

Fix test_write(): copy support.PIPE_MAX_SIZE bytes, not support.PIPE_MAX_SIZE*3
bytes.

files:
  Lib/test/eintrdata/eintr_tester.py |  4 ++--
  1 files changed, 2 insertions(+), 2 deletions(-)


diff --git a/Lib/test/eintrdata/eintr_tester.py b/Lib/test/eintrdata/eintr_tester.py
--- a/Lib/test/eintrdata/eintr_tester.py
+++ b/Lib/test/eintrdata/eintr_tester.py
@@ -144,14 +144,14 @@
         # rd closed explicitly by parent
 
         # we must write enough data for the write() to block
-        data = b"xyz" * support.PIPE_MAX_SIZE
+        data = b"x" * support.PIPE_MAX_SIZE
 
         code = '\n'.join((
             'import io, os, sys, time',
             '',
             'rd = int(sys.argv[1])',
             'sleep_time = %r' % self.sleep_time,
-            'data = b"xyz" * %s' % support.PIPE_MAX_SIZE,
+            'data = b"x" * %s' % support.PIPE_MAX_SIZE,
             'data_len = len(data)',
             '',
             '# let the parent block on write()',

-- 
Repository URL: https://hg.python.org/cpython


More information about the Python-checkins mailing list