2016-11-26 | Paul Boddie | raw files shortlog changelog graph | Added another failure test. | |
tests/methods_unbound.py (file) |
1.1 --- a/tests/methods_unbound.py Sat Nov 26 13:33:49 2016 +0100 1.2 +++ b/tests/methods_unbound.py Sat Nov 26 16:16:21 2016 +0100 1.3 @@ -77,6 +77,12 @@ 1.4 print "f(C, 1): Unbound method is not callable." 1.5 1.6 print f(c, 1) # 1 1.7 + 1.8 +try: 1.9 + print f(d, 1) # should fail with an error caused by a guard 1.10 +except TypeError: 1.11 + print "f(d, 1): d is not a suitable argument." 1.12 + 1.13 fn = f(C, 0) 1.14 1.15 try: