xref: /aosp_15_r20/external/autotest/server/site_tests/autoupdate_Basic/control.m2n.full (revision 9c5db1993ded3edbeafc8092d69fe5de2ee02df7)
1# Copyright 2021 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
5AUTHOR = "dhaddock, Chromium OS"
6NAME = "autoupdate_Basic.m2n.full"
7TIME = "MEDIUM"
8PURPOSE = "Tests an M-to-N update with Nebraska."
9TEST_CATEGORY = "Functional"
10TEST_CLASS = "platform"
11TEST_TYPE = "server"
12ATTRIBUTES = "suite:bvt-inline"
13JOB_RETRIES = 2
14PY_VERSION = 3
15DOC = """
16This tests an M-to-N update. That means it will update from the current stable
17version for this board to ToT. This test will be used in the CQ to ensure
18changes don't break autoupdate.
19
20In the lab, a job_repo_url will be passed directly to the test. It contains
21information about the build to use and the IP address of lab cache server to
22download update payloads from. Local runs can use cache servers as well but
23the setup is fairly complicated. Instead, local test runs can specify the
24`running_at_desk` and `build` args to run without requiring special setup.
25
26Example usage:
27
28With lab cache server SSH access and a job_repo_url:
29test_that <DUT> autoupdate_Basic.m2n.full --args="job_repo_url='http://<IP>:<port>/static/<board>-release/RXX-XXXX.X.X/autotest/packages'"
30
31Otherwise, the running_at_desk and build args are required:
32test_that <DUT> autoupdate_Basic.m2n.full --board=<board> --args="running_at_desk=True build=R102-14643.0.0"
33
34"""
35
36from autotest_lib.client.common_lib import utils
37args_dict = utils.args_to_dict(args)
38
39def run(machine):
40    host = hosts.create_host(machine)
41    job.run_test('autoupdate_Basic', host=host, full_payload=True,
42    		 m2n=True, **args_dict)
43
44job.parallel_simple(run, machines)
45