import types


def is_value_generator(candidate_values):
    """ Returns whether the argument is a value generator
    """
    VALUE_GENERATOR_WRAPPER_FUNC_NAME = "value_generator_wrapper"
    return isinstance(candidate_values, types.FunctionType) and\
            candidate_values.__name__ == VALUE_GENERATOR_WRAPPER_FUNC_NAME