Temporarily commented out docs Mock decorator conditional

This worked in the smaller salt-api project but is choking somewhere in
the larger Salt project. We do need this but we need the salt-api merge
sooner. Commented out for now.
This commit is contained in:
Seth House 2014-06-18 23:20:25 -06:00
parent 1d676fe051
commit 295e0b9060

View file

@ -27,8 +27,8 @@ class Mock(object):
def __call__(self, *args, **kwargs):
ret = Mock()
# If mocked function is used as a decorator, expose decorated function.
if args and callable(args[0]):
functools.update_wrapper(ret, args[0])
# if args and callable(args[-1]):
# functools.update_wrapper(ret, args[0])
return ret
@classmethod