blob: e56974c603dee4fd33895a33de8e6921ef64279e [file] [log] [blame]
# Copyright (c) 2013 The Chromium OS Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import pipes
from autotest_lib.client.common_lib import utils
AUTHOR = "cmtice@chromium.org c-compiler-chrome@google.com"
NAME = "telemetry_Crosperf"
TIME = "LONG"
TEST_CATEGORY = "Benchmark"
TEST_CLASS = "performance"
TEST_TYPE = "server"
DOC = """
This runs various Telemetry performance tests under the crosperf script.
This is part of Chrome OS Toolchain testing platform.
"""
# TODO: The profiler is not quite working properly yet. Need to fix this.
profiler = None
profiler_args = None
# Put the args into the args_dict.
args_dict = utils.args_to_dict(args)
if 'profiler' in args_dict:
profiler = args_dict['profiler']
if 'profiler_args' in args_dict:
p_args = args_dict['profiler_args']
profiler_args = 'perf_options=' + pipes.quote(p_args)
if profiler:
job.default_profile_only = True
job.profilers.add(profiler, profiler_args)
def run_telemetry_Crosperf(machine):
job.run_test('telemetry_Crosperf', client_ip=machine,
args=args_dict)
# run the test in multiple machines
job.parallel_simple(run_telemetry_Crosperf, machines)
if profiler:
job.profilers.delete (profiler)