def test_default_values_of_no_args(): def f(): pass defaults = utils.default_values_of(f) assert defaults == []
def test_default_values_of(): def f(a, b=2, c=None, *args, **kwargs): pass defaults = utils.default_values_of(f) assert defaults == ["b", "c", "args", "kwargs"]
def test_default_values_of(): def f(a, b=2, c=None, *args, **kwargs): pass defaults = utils.default_values_of(f) assert defaults == ['b', 'c', 'args', 'kwargs']