code: def test_fatal_error(self):
      eq = self.assertEqual
      with captured_output("__stderr__") as err, mock.patch(
          "idlelib.run.thread.interrupt_main", new_callable=Func
      ) as func:
          try:
              raise EOFError
          except EOFError:
              run.MyRPCServer.handle_error(None, "abc", "123")
          eq(run.exit_now, True)
          run.exit_now = False
          eq(err.getvalue(), "")
  
          try:
              raise IndexError
          except IndexError:
              run.MyRPCServer.handle_error(None, "abc", "123")
          eq(run.quitting, True)
          run.quitting = False
          msg = err.getvalue()
          self.assertIn("abc", msg)
          self.assertIn("123", msg)
          self.assertIn("IndexError", msg)
          eq(func.called, 2)
  
imports: from idlelib import run
  import io
  import sys
  from test.support import captured_output, captured_stderr
  import unittest
  from unittest import mock
  import idlelib
  from idlelib.idle_test.mock_idle import Func
label_desc: Use image node_id 1 for calling the HandleErrorTest obj's underlying member method code with example usage: obj.test_fatal_error() without return types