Result#

class compliance_checker.base.Result(weight=2, value=None, name=None, msgs=None, children=None, checker=None, check_method=None, variable_name=None)[source]#

Holds the result of a check method.

Stores such information as the check’s value (True, False, a 2-tuple of (pass, total) or None for a skip), weight of the check, any granular messages, or a hierarchy of results. If given value is not a tuple, it is cast as a boolean using the bool() function.

Stores the checker instance and the check method that produced this result.

Methods

serialize()

Returns a serializable dictionary that represents the result object

Methods Summary

__init__([weight, value, name, msgs, ...])

serialize()

Returns a serializable dictionary that represents the result object

Methods Documentation

__init__(weight=2, value=None, name=None, msgs=None, children=None, checker=None, check_method=None, variable_name=None)[source]#
serialize()[source]#

Returns a serializable dictionary that represents the result object