code: def assert_trace_line_count(self, fn, count, filtering_enabled=True):
      trace_line_count = -1
      if filtering_enabled:
          traceback_utils.enable_traceback_filtering()
      else:
          traceback_utils.disable_traceback_filtering()
      self.assertEqual(
          traceback_utils.is_traceback_filtering_enabled(),
          filtering_enabled,
      )
      try:
          fn()
      except Exception as e:  # pylint: disable=broad-except
          # We must count lines rather than frames because autograph transforms
          # stack frames into a single large string
          trace = "\n".join(traceback.format_tb(e.__traceback__))
          trace_line_count = len(trace.split("\n"))
  
      self.assertGreater(trace_line_count, 0)
  
      if filtering_enabled:
          self.assertLess(trace_line_count, count)
      else:
          self.assertGreater(trace_line_count, count)
  
file_path: tensorflow-upstream/tensorflow/python/util/traceback_utils_test.py
imports: import traceback
  from tensorflow.python.eager import def_function
  from tensorflow.python.framework import ops
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import math_ops
  from tensorflow.python.ops import variables
  from tensorflow.python.platform import test
  from tensorflow.python.util import traceback_utils
label_desc: Use image node_id 1 for calling the TracebackUtilsTest obj's underlying member method code with example usage: obj.assert_trace_line_count(fn, count, filtering_enabled) without return types