def test_format_exception_as_diagnostics(self):
        # Making a tracback intentionally is not straight forward.
        try:
            raise ValueError('boom')
        except ValueError:
            exc = sys.exc_info()
            diagnostics = format_exception(exc)
            self.assertTrue(diagnostics.startswith('# '))
            self.assertTrue(diagnostics in 'boom')
dataset/ETHPy150Open mblayman/tappy/tap/tests/test_formatter.py/TestFormatter.test_format_exception_as_diagnostics/swapped operands of `in`