summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2009-05-09 17:21:13 (GMT)
committerBenjamin Peterson <benjamin@python.org>2009-05-09 17:21:13 (GMT)
commit053c61f67cffb1b33210259236a1383051f10a9a (patch)
treeef8a684c8c626e5b6f1c88a6855f3baa3fee4d57 /Lib
parentbe720e0369b6b8a97ceab4a4f8f8930911bd1b75 (diff)
downloadcpython-053c61f67cffb1b33210259236a1383051f10a9a.zip
cpython-053c61f67cffb1b33210259236a1383051f10a9a.tar.gz
cpython-053c61f67cffb1b33210259236a1383051f10a9a.tar.bz2
Merged revisions 72495 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk ........ r72495 | benjamin.peterson | 2009-05-08 21:07:04 -0500 (Fri, 08 May 2009) | 1 line lookup __reversed__ correctly as a special method ........
Diffstat (limited to 'Lib')
-rw-r--r--Lib/test/test_descr.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/Lib/test/test_descr.py b/Lib/test/test_descr.py
index 37cab01..b4bd948 100644
--- a/Lib/test/test_descr.py
+++ b/Lib/test/test_descr.py
@@ -1549,12 +1549,15 @@ order (MRO) for bases """
return self
def hello(self):
return b"hello"
+ def empty_seq(self):
+ return []
# It would be nice to have every special method tested here, but I'm
# only listing the ones I can remember outside of typeobject.c, since it
# does it right.
specials = [
("__bytes__", bytes, hello),
+ ("__reversed__", reversed, empty_seq),
# These two fail because the compiler generates LOAD_ATTR to look
# them up. We'd have to add a new opcode to fix this, and it's
# probably not worth it.