def test_wasSuccessfulFalseAfterFailures(self):
        """
        wasSuccessful() becomes False after failures have been reported.
        """
        try:
            self.fail("foo")
        except self.failureException:
            self.result.addFailure(self.test, sys.exc_info())
        self.assertEqual(False, self.result.wasSuccessful())

        wasSuccessful() becomes False after failures have been reported.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/trial/test/test_reporter.py