summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2008-12-24 15:10:27 (GMT)
committerBenjamin Peterson <benjamin@python.org>2008-12-24 15:10:27 (GMT)
commit54686e3c2981a18521db088ffc16d5f4e5983e75 (patch)
tree86afa9a9a67921ac67eecdeba04681deca334843 /Lib
parente098c4abe5d17fdd469d84ae740eb8bbd8ba9667 (diff)
downloadcpython-54686e3c2981a18521db088ffc16d5f4e5983e75.zip
cpython-54686e3c2981a18521db088ffc16d5f4e5983e75.tar.gz
cpython-54686e3c2981a18521db088ffc16d5f4e5983e75.tar.bz2
#4736 BufferRWPair.closed shouldn't try to call another property as a function
Diffstat (limited to 'Lib')
-rw-r--r--Lib/io.py2
-rw-r--r--Lib/test/test_io.py3
2 files changed, 3 insertions, 2 deletions
diff --git a/Lib/io.py b/Lib/io.py
index 7f93898..320a4b9 100644
--- a/Lib/io.py
+++ b/Lib/io.py
@@ -1167,7 +1167,7 @@ class BufferedRWPair(BufferedIOBase):
@property
def closed(self):
- return self.writer.closed()
+ return self.writer.closed
class BufferedRandom(BufferedWriter, BufferedReader):
diff --git a/Lib/test/test_io.py b/Lib/test/test_io.py
index 8a7da60..967018e 100644
--- a/Lib/test/test_io.py
+++ b/Lib/test/test_io.py
@@ -554,8 +554,9 @@ class BufferedRWPairTest(unittest.TestCase):
r = MockRawIO(())
w = MockRawIO()
pair = io.BufferedRWPair(r, w)
+ self.assertFalse(pair.closed)
- # XXX need implementation
+ # XXX More Tests
class BufferedRandomTest(unittest.TestCase):