tools/nocompile_driver.py
def WriteStats(resultlog, suite_name, timings):
  """Logs the peformance timings for each stage of the script.

  Args:
    resultlog: File object for the log file.
    suite_name: The name of the GUnit suite this test belongs to.
    timings: Dictionary with timestamps for each stage of the script run.
  """
  stats_template = """
TEST(%s): Started %f, Ended %f, Total %fs, Extract %fs, Compile %fs, Process %fs
"""
  total_secs = timings['results_processed'] - timings['started']
  extract_secs = timings['extract_done'] - timings['started']
  compile_secs = timings['compile_done'] - timings['extract_done']
  process_secs = timings['results_processed'] - timings['compile_done']
  resultlog.write(stats_template % (
      suite_name, timings['started'], timings['results_processed'], total_secs,
      extract_secs, compile_secs, process_secs))
Logs the peformance timings for each stage of the script.

  Args:
    resultlog: File object for the log file.
    suite_name: The name of the GUnit suite this test belongs to.
    timings: Dictionary with timestamps for each stage of the script run.
  
Logs the peformance timings for each stage of the script.
Logs the peformance timings for each stage of the script .
def WriteStats(resultlog, suite_name, timings):
  stats_template = """
TEST(%s): Started %f, Ended %f, Total %fs, Extract %fs, Compile %fs, Process %fs
"""
  total_secs = timings['results_processed'] - timings['started']
  extract_secs = timings['extract_done'] - timings['started']
  compile_secs = timings['compile_done'] - timings['extract_done']
  process_secs = timings['results_processed'] - timings['compile_done']
  resultlog.write(stats_template % (
      suite_name, timings['started'], timings['results_processed'], total_secs,
      extract_secs, compile_secs, process_secs))
def WriteStats ( resultlog , suite_name , timings ) : stats_template = """
TEST(%s): Started %f, Ended %f, Total %fs, Extract %fs, Compile %fs, Process %fs
""" total_secs = timings [ 'results_processed' ] - timings [ 'started' ] extract_secs = timings [ 'extract_done' ] - timings [ 'started' ] compile_secs = timings [ 'compile_done' ] - timings [ 'extract_done' ] process_secs = timings [ 'results_processed' ] - timings [ 'compile_done' ] resultlog . write ( stats_template % ( suite_name , timings [ 'started' ] , timings [ 'results_processed' ] , total_secs , extract_secs , compile_secs , process_secs ) )
Logs the peformance timings for each stage of the script.
Logs the peformance timings for each stage of the script .
"""Logs the peformance timings for each stage of the script.

  Args:
    resultlog: File object for the log file.
    suite_name: The name of the GUnit suite this test belongs to.
    timings: Dictionary with timestamps for each stage of the script run.
  """
resultlog
File object for the log file.
File object for the log file .
suite_name
The name of the GUnit suite this test belongs to.
The name of the GUnit suite this test belongs to .
timings
Dictionary with timestamps for each stage of the script run.
Dictionary with timestamps for each stage of the script run .