def addExpectedFailure(self, test, failure, todo):
        failure = util.excInfoOrFailureToExcInfo(failure)
        addExpectedFailure = getattr(self._subunit, 'addExpectedFailure', None)
        if addExpectedFailure is None:
            self.addSuccess(test)
        else:
            addExpectedFailure(test, failure)
Record an expected failure from a test.
dataset/ETHPy150Open twisted/twisted/twisted/trial/reporter.py/SubunitReporter.addExpectedFailure