def validate(self, tests=None): config = package_config.PackageConfig.get_config() # TODO: check if config is None well_test = self.__create_well_done("well_done_test") if tests is None: tests = utests.get_tests() if 'validator' in config and config['validator'] not in ["", None]: validator_src = config["validator"] else: validator_src = None logger.warning("Validator is empty") logger.warning("General validator (well_done) is on") well_done_with_validator = WellDoneWithValidator( validator=validator_src, well_done=well_test) for num, test in enumerate(tests): well_done_with_validator.validate(test, num+1)
def validate(self, tests=None): config = package_config.PackageConfig.get_config() # TODO: check if config is None well_test = self.__create_well_done("well_done_test") if tests is None: tests = utests.get_tests() if 'validator' in config and config['validator'] not in ["", None]: validator_src = config["validator"] else: validator_src = None logger.warning("Validator is empty") logger.warning("General validator (well_done) is on") well_done_with_validator = WellDoneWithValidator( validator=validator_src, well_done=well_test) for num, test in enumerate(tests): well_done_with_validator.validate(test, num + 1)
from please.log import logger logger.debug('DEBUG') logger.info('INFO') logger.warning('WARNING') logger.error('ERROR') logger.critical('CRITICAL')