class_docstr: Tests for frame.clear().
class_docstr_tok: ["Tests","for","frame.clear","(",")","."]
code: def test_clear_executing(self):
      # Attempting to clear an executing frame is forbidden.
      try:
          1 / 0
      except ZeroDivisionError as e:
          f = e.__traceback__.tb_frame
      with self.assertRaises(RuntimeError):
          f.clear()
      with self.assertRaises(RuntimeError):
          f.f_back.clear()
  
imports: import gc
  import operator
  import re
  import sys
  import textwrap
  import threading
  import types
  import unittest
  import weakref
  from test import support
  from test.support import threading_helper
  from test.support.script_helper import assert_python_ok
label_desc: Use image node_id 7 for calling the ClearTest obj's underlying member method code with example usage: obj.test_clear_executing() without return types