示例#1
0
    def test_callable_argspec_method(self):
        class Foo(object):
            def foo(self, x, y, **kw):
                pass

        eq_(get_callable_argspec(Foo.foo),
            (['self', 'x', 'y'], None, 'kw', None))
示例#2
0
 def test_callable_argspec_fn(self):
     def foo(x, y, **kw):
         pass
     eq_(
         get_callable_argspec(foo),
         (['x', 'y'], None, 'kw', None)
     )
示例#3
0
 def test_callable_argspec_method(self):
     class Foo(object):
         def foo(self, x, y, **kw):
             pass
     eq_(
         get_callable_argspec(Foo.foo),
         (['self', 'x', 'y'], None, 'kw', None)
     )
示例#4
0
    def test_callable_argspec_fn(self):
        def foo(x, y, **kw):
            pass

        eq_(get_callable_argspec(foo), (['x', 'y'], None, 'kw', None))