Skip to content

Commit abac3b6

Browse files
committed
Expect an AttributeError on Py3 in test_magicsuper
1 parent a7f1cb0 commit abac3b6

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

future/tests/test_magicsuper.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,10 @@ def not_a_method():
6565
self.assertRaises(RuntimeError,not_a_method)
6666
def not_a_method(self):
6767
super().not_a_method()
68-
self.assertRaises(RuntimeError,not_a_method,self)
68+
if utils.PY2:
69+
self.assertRaises(RuntimeError,not_a_method,self)
70+
else:
71+
self.assertRaises(AttributeError,not_a_method,self)
6972

7073
def assertSuperEquals(self,sobj1,sobj2):
7174
assert sobj1.__self__ is sobj2.__self__

0 commit comments

Comments
 (0)