[pypy-svn] r57133 - in pypy/branch/isinstance-refactor/pypy/rlib: . test
arigo at codespeak.net
arigo at codespeak.net
Sat Aug 9 16:10:34 CEST 2008
Author: arigo
Date: Sat Aug 9 16:10:34 2008
New Revision: 57133
Modified:
pypy/branch/isinstance-refactor/pypy/rlib/rStringIO.py
pypy/branch/isinstance-refactor/pypy/rlib/test/test_rStringIO.py
Log:
Fix the test by restoring a broken invariant.
Modified: pypy/branch/isinstance-refactor/pypy/rlib/rStringIO.py
==============================================================================
--- pypy/branch/isinstance-refactor/pypy/rlib/rStringIO.py (original)
+++ pypy/branch/isinstance-refactor/pypy/rlib/rStringIO.py Sat Aug 9 16:10:34 2008
@@ -45,6 +45,8 @@
return ''.join(self.bigbuffer)
if self.numstrings > 1:
result = self.strings[0] = ''.join(self.strings)
+ for i in range(1, self.numstrings):
+ self.strings[i] = ''
self.numstrings = 1
self.numbigstrings = 1
else:
Modified: pypy/branch/isinstance-refactor/pypy/rlib/test/test_rStringIO.py
==============================================================================
--- pypy/branch/isinstance-refactor/pypy/rlib/test/test_rStringIO.py (original)
+++ pypy/branch/isinstance-refactor/pypy/rlib/test/test_rStringIO.py Sat Aug 9 16:10:34 2008
@@ -96,7 +96,6 @@
assert f.tell() == 3
def test_bug():
- import py; py.test.skip("in-progress")
f = RStringIO()
f.write('0')
f.write('1')
More information about the Pypy-commit
mailing list