2008-08-27 | Paul Boddie | raw files shortlog changelog graph | Added another test of method invocation, explicitly testing instance/class compatibility for supplied contexts. | |
tests/call_method3.py (file) |
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/tests/call_method3.py Wed Aug 27 00:45:14 2008 +0200 1.3 @@ -0,0 +1,12 @@ 1.4 +#!/usr/bin/env python 1.5 + 1.6 +class C: 1.7 + def f(self, a, b, c): 1.8 + pass 1.9 + 1.10 +c = C() 1.11 + 1.12 +f = C.f 1.13 +f(c, 1, 2, 3) # test self argument 1.14 + 1.15 +# vim: tabstop=4 expandtab shiftwidth=4