blob: edd856fe42edf653d5fa8e41eb2896b1d6c37a15 [file] [log] [blame]
# Copyright 2023 The ChromiumOS Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
NAME = "power_LW.tast_power_Idle_lacros_v_ash"
METADATA = {
"contacts": ["chromeos-platform-power@google.com", "yanyeli@google.com"],
"bug_component": "b:1361410",
"criteria": "This test is a power benchmark test.",
"hw_agnostic": False,
"doc" : "Control file for running tast.power.ExampleUI (Idle test) for Ash"
"and Lacros in power lab. This is done with one control file "
"instead of two to ensure that both runs of power.ExampleUI are"
"executed on the same DUT, reducing variability. Even if two DUTs "
"are the same SKU, chip variability means that power consumption "
"characteristics will differ.",
}
TEST_TYPE = "server"
DEPENDENCIES = "servo_state:WORKING"
EXTENDED_TIMEOUT = 18000 # 40 mins of Idle + 4 hours charging + 20 mins guard.
from autotest_lib.client.common_lib import utils
args_dict = utils.args_to_dict(args)
servo_args = hosts.CrosHost.get_servo_arguments(args_dict)
test = 'tast'
args_ash = {'test_exprs': ["power.ExampleUI.ash"],
'max_run_sec': 1500,
'clear_tpm': False,
'tag': 'ash'}
args_lacros = {'test_exprs': ["power.ExampleUI.lacros"],
'max_run_sec': 1500,
'clear_tpm': False,
'tag': 'lacros'}
def run(machine):
host = hosts.create_host(machine, servo_args=servo_args)
job.run_test("power_BatteryDrainControl", host=host,
drain_to_percent=75, tag="lacros")
job.run_test("power_BatteryChargeControl", host=host,
percent_charge_to_add=None, percent_target_charge=75,
tag="lacros")
job.run_test("power_LW", host=host, test=test, args=args_lacros,
machine=machine, server_test=True,
tag="lacros")
job.run_test("power_BatteryDrainControl", host=host,
drain_to_percent=75, tag="ash")
job.run_test("power_BatteryChargeControl", host=host,
percent_charge_to_add=None, percent_target_charge=75,
tag="ash")
job.run_test("power_LW", host=host, test=test, args=args_ash,
machine=machine, server_test=True,
tag="ash")
parallel_simple(run, machines)