diff options
| author | Benjamin Peterson <benjamin@python.org> | 2009-12-13 17:29:16 (GMT) |
|---|---|---|
| committer | Benjamin Peterson <benjamin@python.org> | 2009-12-13 17:29:16 (GMT) |
| commit | 414721614f6f550f8d8353b09b178e1d055f1d1f (patch) | |
| tree | a5f69d893fc93c290aa5e7801abe5f518b27774a /Lib/test/test_StringIO.py | |
| parent | 4895af4ef1c91679e642c0fc81f584aecc26a7ea (diff) | |
| download | cpython-414721614f6f550f8d8353b09b178e1d055f1d1f.zip cpython-414721614f6f550f8d8353b09b178e1d055f1d1f.tar.gz cpython-414721614f6f550f8d8353b09b178e1d055f1d1f.tar.bz2 | |
make StringIO like other file objects in that readline(-1) has no effect #7348
Diffstat (limited to 'Lib/test/test_StringIO.py')
| -rw-r--r-- | Lib/test/test_StringIO.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/test/test_StringIO.py b/Lib/test/test_StringIO.py index f5a177e..d10255d 100644 --- a/Lib/test/test_StringIO.py +++ b/Lib/test/test_StringIO.py @@ -28,6 +28,8 @@ class TestGenericStringIO(unittest.TestCase): eq(self._fp.read(10), self._line[:10]) eq(self._fp.readline(), self._line[10:] + '\n') eq(len(self._fp.readlines(60)), 2) + self._fp.seek(0) + eq(self._fp.readline(-1), self._line + '\n') def test_writes(self): f = self.MODULE.StringIO() |
