Author: Benjamin Peterson <[email protected]>
Branch: 
Changeset: r44523:59dbc231c86a
Date: 2011-05-26 12:24 -0500
http://bitbucket.org/pypy/pypy/changeset/59dbc231c86a/

Log:    returning None in __len__ is not acceptable; use a different
        operation

diff --git a/pypy/module/test_lib_pypy/test_tputil.py 
b/pypy/module/test_lib_pypy/test_tputil.py
--- a/pypy/module/test_lib_pypy/test_tputil.py
+++ b/pypy/module/test_lib_pypy/test_tputil.py
@@ -28,9 +28,9 @@
         from tputil import make_proxy 
         l = []
         tp = make_proxy(l.append, type=list)
-        x = len(tp)
+        x = tp[0:1]
         assert len(l) == 1
-        assert l[0].opname == '__len__'
+        assert l[0].opname == '__getslice__'
        
     def test_simple(self):
         from tputil import make_proxy 
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to