1# Copyright 2014 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
5from autotest_lib.server import utils
6
7NAME = "infra_ServoDiagnosis"
8AUTHOR = "Chrome OS Team"
9TIME = "LONG"
10TEST_CATEGORY = "Stress"
11TEST_CLASS = "platform"
12TEST_TYPE = "server"
13
14# N.B.  We deliberately do not say DEPENDENCIES = "servo"; a key
15# requirement of this test is that we detect and repair a missing
16# servo label.
17
18
19DOC = """
20Test and diagnose the status of a servo attached to a given host.
21"""
22
23# We'd like to do the following, so that this test can be run
24# from a desktop, but the code below will cause the test not
25# to run if the servo is down, which prevents diagnosis.
26
27# args_dict = utils.args_to_dict(args)
28# servo_args = hosts.CrosHost.get_servo_arguments(args_dict)
29
30def run(machine):
31    host = hosts.create_host(machine, try_lab_servo=True)
32    job.run_test("infra_ServoDiagnosis", host=host)
33
34parallel_simple(run, machines)
35