1 # Copyright (c) 2013 The Chromium OS Authors. All rights reserved. 2 # Use of this source code is governed by a BSD-style license that can be 3 # found in the LICENSE file. 4 5 6 AUTHOR = "chromeos-lab-infrastructure" 7 NAME = "provision_FirmwareUpdate" 8 PURPOSE = "Provision a system to the correct firmware version." 9 TIME = "MEDIUM" 10 TEST_CATEGORY = "System" 11 TEST_CLASS = "provision" 12 TEST_TYPE = "Server" 13 14 DOC = """ 15 This is a test used by the provision control segment in autoserv to set the 16 fwro-version label of a host to the desired setting. This test attempts to 17 reprogram both EC and AP firmware. 18 """ 19 20 21 from autotest_lib.client.common_lib import error, utils 22 23 24 args_dict = utils.args_to_dict(args) 25 servo_args = hosts.CrosHost.get_servo_arguments(args_dict) 26 27 28 if not locals().get('value'): 29 if not args_dict.get('value'): 30 raise error.TestError("No provision value!") 31 value = args_dict['value'] 32 33 34 def run(machine): 35 host = hosts.create_host(machine, servo_args=servo_args) 36 job.run_test('provision_FirmwareUpdate', host=host, value=value, 37 rw_only=False, disable_sysinfo=True) 38 39 40 job.parallel_simple(run, machines) 41