def set_verdict(self, verdict, retcode=-1, duration=-1):
        """
        Set the final verdict for this Result.

        :param verdict: Verdict, must be from ['pass', 'fail', 'unknown', 'skip', 'inconclusive']'
        :param retcode: integer return code
        :param duration: test duration
        :return: Nothing
        :raises: ValueError if verdict was unknown.
        """
        verdict = verdict.lower()
        if not verdict in ['pass', 'fail', 'unknown', 'skip', 'inconclusive']:
            raise ValueError("Unknown verdict {}".format(verdict))
        if retcode == -1 and verdict == 'pass':
            retcode = 0
        self.__verdict = verdict
        self.retcode = retcode
        if duration >= 0:
            self.duration = duration