code: def testHorizontal(self):
      table = type_dispatch.TypeDispatchTable()
      table.add_target(
          make_shape_function_type(
              1,
          )
      )
      table.add_target(make_shape_function_type(1, 2))
      table.add_target(make_shape_function_type(1, 2, 3))
      self.assertEqual(
          list(table.targets),
          [
              make_shape_function_type(
                  1,
              ),
              make_shape_function_type(1, 2),
              make_shape_function_type(1, 2, 3),
          ],
      )
  
imports: from typing import Optional
  from tensorflow.core.function.polymorphism import function_type
  from tensorflow.core.function.polymorphism import type_dispatch
  from tensorflow.python.platform import test
  from tensorflow.python.types import trace
label_desc: Use image node_id 2 for calling the TypeDispatchTableTest obj's underlying member method code with example usage: obj.testHorizontal() without return types