human
I wrote the below code

    def decorator(view_func):
        @wraps(view_func)
        def wrapped_view_func(request, *args, **kwargs):
            if test(request.user):
                return view_func(request, *args, **kwargs)
            else:
                return permission_denied(request)
        return wrapped_view_func
    return decorator

What's a good function header?

=====
Here's a good function header?
assistant
#Here's a good function header.

def user_passes_test(test):