content/test/gpu/flake_suppressor/result_output.py
def GenerateHtmlOutputFile(aggregated_results, outfile=None):
  """Generates an HTML results file.

  Args:
    aggregated_results: A map containing the aggregated test results.
    outfile: A file-like object to output to. Will create one if not provided.
  """
  outfile = outfile or tempfile.NamedTemporaryFile(
      mode='w', delete=False, suffix='.html')
  try:
    outfile.write('<html>\n<body>\n')
    string_map = _ConvertAggregatedResultsToStringMap(aggregated_results)
    _OutputMapToHtmlFile(string_map, 'Grouped By Test', outfile)
    config_map = _ConvertFromTestGroupingToConfigGrouping(string_map)
    _OutputMapToHtmlFile(config_map, 'Grouped By Config', outfile)
    outfile.write('</body>\n</html>\n')
  finally:
    outfile.close()
  print('HTML results: %s' % outfile.name)
Generates an HTML results file.

  Args:
    aggregated_results: A map containing the aggregated test results.
    outfile: A file-like object to output to. Will create one if not provided.
  
Generates an HTML results file.
Generates an HTML results file .
def GenerateHtmlOutputFile(aggregated_results, outfile=None):
  outfile = outfile or tempfile.NamedTemporaryFile(
      mode='w', delete=False, suffix='.html')
  try:
    outfile.write('<html>\n<body>\n')
    string_map = _ConvertAggregatedResultsToStringMap(aggregated_results)
    _OutputMapToHtmlFile(string_map, 'Grouped By Test', outfile)
    config_map = _ConvertFromTestGroupingToConfigGrouping(string_map)
    _OutputMapToHtmlFile(config_map, 'Grouped By Config', outfile)
    outfile.write('</body>\n</html>\n')
  finally:
    outfile.close()
  print('HTML results: %s' % outfile.name)
def GenerateHtmlOutputFile ( aggregated_results , outfile = None ) : outfile = outfile or tempfile . NamedTemporaryFile ( mode = 'w' , delete = False , suffix = '.html' ) try : outfile . write ( '<html>\n<body>\n' ) string_map = _ConvertAggregatedResultsToStringMap ( aggregated_results ) _OutputMapToHtmlFile ( string_map , 'Grouped By Test' , outfile ) config_map = _ConvertFromTestGroupingToConfigGrouping ( string_map ) _OutputMapToHtmlFile ( config_map , 'Grouped By Config' , outfile ) outfile . write ( '</body>\n</html>\n' ) finally : outfile . close ( ) print ( 'HTML results: %s' % outfile . name )
Generates an HTML results file.
Generates an HTML results file .
"""Generates an HTML results file.

  Args:
    aggregated_results: A map containing the aggregated test results.
    outfile: A file-like object to output to. Will create one if not provided.
  """
aggregated_results
A map containing the aggregated test results.
A map containing the aggregated test results .
outfile
A file-like object to output to. Will create one if not provided.
A file - like object to output to . Will create one if not provided .