summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorNeal Norwitz <nnorwitz@gmail.com>2006-03-17 08:29:44 (GMT)
committerNeal Norwitz <nnorwitz@gmail.com>2006-03-17 08:29:44 (GMT)
commit7096760b2511df9b0e2ec846df9eb72c59e785fc (patch)
tree24a93465b1325a58b51e00eaf3924c5ec4bffd33 /Lib
parent7c3072437a8f2e4cd487e38d46ea99d0026bd4c2 (diff)
downloadcpython-7096760b2511df9b0e2ec846df9eb72c59e785fc.zip
cpython-7096760b2511df9b0e2ec846df9eb72c59e785fc.tar.gz
cpython-7096760b2511df9b0e2ec846df9eb72c59e785fc.tar.bz2
Get rid of xreadlines() (methods).
Diffstat (limited to 'Lib')
-rw-r--r--Lib/rexec.py2
-rw-r--r--Lib/test/test_bz2.py10
-rw-r--r--Lib/test/test_decimal.py2
-rw-r--r--Lib/test/test_file.py2
4 files changed, 4 insertions, 12 deletions
diff --git a/Lib/rexec.py b/Lib/rexec.py
index 89ff509..ed01d24 100644
--- a/Lib/rexec.py
+++ b/Lib/rexec.py
@@ -29,7 +29,7 @@ __all__ = ["RExec"]
class FileBase:
ok_file_methods = ('fileno', 'flush', 'isatty', 'read', 'readline',
- 'readlines', 'seek', 'tell', 'write', 'writelines', 'xreadlines',
+ 'readlines', 'seek', 'tell', 'write', 'writelines',
'__iter__')
diff --git a/Lib/test/test_bz2.py b/Lib/test/test_bz2.py
index 504a6d7..356c2e3 100644
--- a/Lib/test/test_bz2.py
+++ b/Lib/test/test_bz2.py
@@ -110,14 +110,6 @@ class BZ2FileTest(BaseTest):
self.assertEqual(list(iter(bz2f)), sio.readlines())
bz2f.close()
- def testXReadLines(self):
- # "Test BZ2File.xreadlines()"
- self.createTempFile()
- bz2f = BZ2File(self.filename)
- sio = StringIO(self.TEXT)
- self.assertEqual(list(bz2f.xreadlines()), sio.readlines())
- bz2f.close()
-
def testUniversalNewlinesLF(self):
# "Test BZ2File.read() with universal newlines (\\n)"
self.createTempFile()
@@ -256,7 +248,7 @@ class BZ2FileTest(BaseTest):
bz2f.close()
self.assertEqual(lines, ['Test'])
bz2f = BZ2File(self.filename)
- xlines = list(bz2f.xreadlines())
+ xlines = list(bz2f.readlines())
bz2f.close()
self.assertEqual(lines, ['Test'])
diff --git a/Lib/test/test_decimal.py b/Lib/test/test_decimal.py
index 34f034b..7d0addf 100644
--- a/Lib/test/test_decimal.py
+++ b/Lib/test/test_decimal.py
@@ -132,7 +132,7 @@ class DecimalTest(unittest.TestCase):
if skip_expected:
raise TestSkipped
return
- for line in open(file).xreadlines():
+ for line in open(file):
line = line.replace('\r\n', '').replace('\n', '')
#print line
try:
diff --git a/Lib/test/test_file.py b/Lib/test/test_file.py
index efb06f4..fd5670a 100644
--- a/Lib/test/test_file.py
+++ b/Lib/test/test_file.py
@@ -179,7 +179,7 @@ for s in (-1, 0, 1, 512):
methods = ['fileno', 'flush', 'isatty', 'next', 'read', 'readinto',
'readline', 'readlines', 'seek', 'tell', 'truncate', 'write',
- 'xreadlines', '__iter__']
+ '__iter__']
if sys.platform.startswith('atheos'):
methods.remove('truncate')