def test_postCaseCleanupNoErrors(self):
        """
        The post-case cleanup method will return True and not call C{addError}
        on the result if there are no pending calls.
        """
        reactor = StubReactor([])
        test = object()
        reporter = StubErrorReporter()
        jan = _Janitor(test, reporter, reactor=reactor)
        self.assertTrue(jan.postCaseCleanup())
        self.assertEqual(reporter.errors, [])

        The post-case cleanup method will return True and not call C{addError}
        on the result if there are no pending calls.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/trial/test/test_util.py