code: def setUpClass(cls):
      requires("gui")
      from Tkinter import Tk, Text
  
      cls.Text = Text
      cls.root = Tk()
  
imports: import unittest
  from test.test_support import requires
  from _tkinter import TclError
label_desc: Use image node_id 1 for calling the TkTextTest obj's underlying member method code with example usage: obj.setUpClass(cls) without return types