Running all conditions in the instance variable valid_list
        Return:
            True: pass all conditions
            False: fail at more than one condition
181464
def verify(self):
        
        if self not in self._queue:
            return False
        valid = True
        for check in self.valid_list:
            valid = valid & check()
        return valid
656564
def check_for_failed_condition(conds)
      failed = (conds || []).find { |c, v| !check_condition?(c, v) }
      if failed
        failed[0] = failed[0][0..-2].to_sym if failed[0][-1] == '!'
      end
      failed
    end
215383
def matches_conditions?(object, query)
        query[:guard] == false ||
        Array(if_condition).all? {|condition| evaluate_method(object, condition)} &&
        !Array(unless_condition).any? {|condition| evaluate_method(object, condition)}
      end
836598
def _all(confs=None, **kwargs):
    

    result = False

    if confs is not None:
        # ensure confs is a list
        if isinstance(confs, string_types) or isinstance(confs, dict):
            confs = [confs]
        # if at least one conf exists, result is True by default
        result = True
        for conf in confs:
            result = run(conf, **kwargs)
            # stop when a result is False
            if not result:
                break

    return result
633426
def _is_valid_options_weights_list(value):
    ''''''
    return ((isinstance(value, list)) and
            len(value) > 1 and
            (all(isinstance(opt, tuple) and
                 len(opt) == 2 and
                 isinstance(opt[1], (int, float))
                 for opt in value)))
667756
def _check_split_list_validity(self):
        
        # FIXME: Currently very primitive, but needs to be fast
        if not (hasattr(self,"_splitListsSet") and (self._splitListsSet)):
            return False
        elif len(self) != self._splitListsLength:
            return False
        else:
            return True
490994
def valid?
      result = true

      selected.each do |view|
        view.rmq_data.validations.each do |validation|

          has_events = view.rmq_data.events

          if validation.valid?(rmq(view).data)
            if has_events && view.rmq_data.events.has_event?(:valid)
              view.rmq_data.events[:valid].fire!
            end
          else
            if has_events && view.rmq_data.events.has_event?(:invalid)
              view.rmq_data.events[:invalid].fire!
            end
            result = false
          end
        end
      end
      return result
    end
1158528
def is_valid(self):
        ''''''
        return (self.is_primitive and self.name) \
            or (self.is_complex and self.name) \
            or (self.is_list and self.nested) \
            or (self.is_map and self.nested) \
            or (self.is_model and self.nested)
1005954
def _validate_str_list(arg):
    '''
    
    '''
    if isinstance(arg, six.binary_type):
        ret = [salt.utils.stringutils.to_unicode(arg)]
    elif isinstance(arg, six.string_types):
        ret = [arg]
    elif isinstance(arg, Iterable) and not isinstance(arg, Mapping):
        ret = []
        for item in arg:
            if isinstance(item, six.string_types):
                ret.append(item)
            else:
                ret.append(six.text_type(item))
    else:
        ret = [six.text_type(arg)]
    return ret
1266335
def is_running(fun):
    '''
    
    '''
    run = running()
    ret = []
    for data in run:
        if fnmatch.fnmatch(data.get('fun', ''), fun):
            ret.append(data)
    return ret
1364739
def check_conditions(f, args, kwargs):
    
    member_function = is_member_function(f)

    # check the functions direct pre conditions
    check_preconditions(f, args, kwargs)

    # for member functions check the pre conditions up the chain
    base_classes = []
    if member_function:
        base_classes = inspect.getmro(type(args[0]))[1:-1]
        for clz in base_classes:
            super_fn = getattr(clz, f.func_name, None)
            check_preconditions(super_fn, args, kwargs)

    # run the real function
    return_value = f(*args, **kwargs)

    # check the functions direct post conditions
    check_postconditions(f, return_value)

    # for member functions check the post conditions up the chain
    if member_function:
        for clz in base_classes:
            super_fn = getattr(clz, f.func_name, None)
            check_postconditions(super_fn, return_value)

    return return_value
674046
def pass_conditions(all_info, current_path, conditions, unknown_as_pass_condition = False):
    
    result = False
    if len(conditions) == 0:
        return True
    condition_operator = conditions.pop(0)
    for condition in conditions:
        if condition[0] in condition_operators:
            res = pass_conditions(all_info, current_path, condition, unknown_as_pass_condition)
        else:
            # Conditions are formed as "path to value", "type of test", "value(s) for test"
            path_to_value, test_name, test_values = condition
            path_to_value = fix_path_string(all_info, current_path, path_to_value)
            target_obj = get_value_at(all_info, current_path, path_to_value)
            if type(test_values) != list:
                dynamic_value = re_get_value_at.match(test_values)
                if dynamic_value:
                    test_values = get_value_at(all_info, current_path, dynamic_value.groups()[0], True)
            try:
                res = pass_condition(target_obj, test_name, test_values)
            except Exception as e:
                res = True if unknown_as_pass_condition else False
                printError('Unable to process testcase \'%s\' on value \'%s\', interpreted as %s.' % (test_name, str(target_obj), res))
                printException(e, True)
        # Quick exit and + false
        if condition_operator == 'and' and not res:
            return False
        # Quick exit or + true
        if condition_operator == 'or' and res:
            return True
    # Still here ?
    # or -> false
    # and -> true
    if condition_operator == 'or':
        return False
    else:
        return True
521696
def valid(self, value, include_name=True):
		

		# Call the parent valid method and return the result
		return super(Tree, self).valid(value, include_name and [self._name] or [])
1256513
def check_condition(condition, defined_variables):
    
    name, op, value = condition['name'], condition['operator'], condition['value']
    operator_type = _get_variable_value(defined_variables, name)
    return _do_operator_comparison(operator_type, op, value)
733557
def check_assertions(self, checklist, all=False):
        

        assert isinstance(checklist, dict) and 'checks' in checklist

        retval = None
        retlist = []

        for assertion in checklist['checks']:
            retval = self.check_assertion(**assertion)
            retlist.append(retval)
            if not retval.success and not all:
                print "Error message:", retval[3]
                return retlist

        return retlist
159830
def __fun_check(self, valid, fun, args=None, kwargs=None):
        '''
        
        '''
        if not isinstance(valid, list):
            valid = [valid]
        for cond in valid:
            # Function name match
            if isinstance(cond, six.string_types):
                if self.match_check(cond, fun):
                    return True
            # Function and args match
            elif isinstance(cond, dict):
                if len(cond) != 1:
                    # Invalid argument
                    continue
                fname_cond = next(six.iterkeys(cond))
                if self.match_check(fname_cond, fun):  # check key that is function name match
                    if self.__args_check(cond[fname_cond], args, kwargs):
                        return True
        return False
868865
def are_valid_values(values):
    
    try:
        int_values = map(int, values)
        for v in int_values:
            if (v >= 0) and (v <= 255):
                continue
            else:
                return False
    except Exception as ex:
        # print(ex)
        return False
    return True