code: def get_testlist(exe, workdir):
      retcode, out = run_cmd("%s --gtest_list_tests" % exe, workdir)
      if retcode != 0:
          print(out)
          raise Exception(
              "Collecting test-list failed! See above errors"
          )
      tests = []
      for line in out.splitlines():
          # only consider fixtures and main tests
          if line[:2] == "  " or line.startswith("Running "):
              continue
          line = CommentRegex.sub("", line)
          tests.append(line + "*")
      return tests
  
file_path: cuml/cpp/scripts/cuda-memcheck.py
imports: from __future__ import print_function
  import os
  import subprocess
  import argparse
  import time
  import re
  import sys
label_desc: Use image node_id 3 for calling a global function with example usage: get_testlist(exe, workdir) and returns: tests