def _check(self):
        """
        Check the output of the log observer to see if the error is present.
        """
        c2 = self._loggedErrors()
        self.assertEqual(len(c2), 2)
        c2[1]["failure"].trap(ZeroDivisionError)
        self.flushLoggedErrors(ZeroDivisionError)

        Check the output of the log observer to see if the error is present.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/test/test_defer.py