def CheckPrerequisites(benchmark_config): """Perform flag checks.""" if 'all' not in FLAGS.blazemark_set: requested = frozenset(FLAGS.blazemark_set) binaries = blazemark.GetBinaries() if requested - binaries: raise errors.Benchmarks.PrepareException( 'Binaries %s not available. Options are %s' % ( requested - binaries, binaries))
def Run(benchmark_spec): """Measure the boot time for all VMs. Args: benchmark_spec: The benchmark specification. Contains all data that is required to run the benchmark. Returns: A list of sample.Sample objects with individual machine boot times. """ vm = benchmark_spec.vms[0] if 'all' not in FLAGS.blazemark_set: run = FLAGS.blazemark_set else: run = blazemark.GetBinaries() results = [] for test in run: logging.info('Running %s', test) results.extend(blazemark.RunTest(vm, test)) return results