[pypy-svn] r79031 - pypy/trunk/pypy/rpython/test

arigo at codespeak.net arigo at codespeak.net
Fri Nov 12 13:02:50 CET 2010


Author: arigo
Date: Fri Nov 12 13:02:49 2010
New Revision: 79031

Modified:
   pypy/trunk/pypy/rpython/test/test_rpbc.py
Log:
Fix: don't catch NotImplementedError.


Modified: pypy/trunk/pypy/rpython/test/test_rpbc.py
==============================================================================
--- pypy/trunk/pypy/rpython/test/test_rpbc.py	(original)
+++ pypy/trunk/pypy/rpython/test/test_rpbc.py	Fri Nov 12 13:02:49 2010
@@ -1547,7 +1547,7 @@
     def test_always_raising_methods(self):
         class Base:
             def m(self):
-                raise NotImplementedError
+                raise KeyError
         class A(Base):
             def m(self):
                 return 42
@@ -1560,11 +1560,11 @@
                 o = B()
             try:
                 o.m()
-            except NotImplementedError:
-                pass
+            except KeyError:
+                assert 0
             return B().m()
 
-        self.interpret_raises(NotImplementedError, f, [7])
+        self.interpret_raises(KeyError, f, [7])
 
     def test_possible_missing_attribute_access(self):
         py.test.skip("Should explode or give some warning")



More information about the Pypy-commit mailing list