def set_status(self, status=None):
        if status is None:
            if not self.result['componentResults']:
                raise Exception("Can't generate overall status without component results")
            status = self._gen_component_status()

        if status not in ['OK', 'ERROR', 'WARN']:
            raise InvalidArgument("Status has to be OK, ERROR or WARN")

        self.result['status'] = status
Set result status
dataset/ETHPy150Open gooddata/smoker/smoker/server/plugins/__init__.py/Result.set_status