code: def _generate_test_cases(
      module_name, base_class, test_case_generator
  ):
      # Returns a list of _TestCaseTuple's holding generated test cases.
      module = sys.modules[module_name]
  
      generated_cases = []
      for cls_name, members, method_generator in test_case_generator(
          base_class
      ):
          c = _generate_case(
              base_class, module, cls_name, members, method_generator
          )
          generated_cases.append(c)
  
      return generated_cases
  
file_path: chainer/chainer/testing/_bundle.py
imports: import collections
  import inspect
  import sys
label_desc: Use image node_id 3 for calling a global function with example usage: _generate_test_cases(module_name, base_class, test_case_generator) and returns: generated_cases