Пример #1
0
    def test_required_args_3(self):
        def test_func(a, b, c, d, e, *args, **kwargs):
            pass

        parser = Parser(test_func)
        self.my_assert(tuple(parser.required_args()),
                       ('a', 'b', 'c', 'd', 'e'))
Пример #2
0
    def test_required_args_1(self):
        def test_func(a, b, c=5, d=1):
            pass

        parser = Parser(test_func)
        self.my_assert(tuple(parser.required_args()), ('a', 'b'))