xref: /aosp_15_r20/external/autotest/test_suites/control.cros_test_platform (revision 9c5db1993ded3edbeafc8092d69fe5de2ee02df7)
1# Copyright 2019 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 = "ChromeOS Test Platform Team"
6NAME = "cros_test_platform"
7PURPOSE = "Entry point for cros_test_platform execution of autotest tests."
8
9DOC = """
10This suite is used as an entry point for cros_test_platform, to allow it to
11inject arbitrary arguments into dynamic_suite.reimage_and_run, by
12supplying these arguments as a json-encoded args dictionary (with name
13args_dict_json).
14
15This suite should not be used for any other purpose.
16"""
17
18import json
19
20import common
21from autotest_lib.server.cros.dynamic_suite import dynamic_suite
22
23
24TIME = "SHORT"
25TEST_CATEGORY = "General"
26TEST_CLASS = "suite"
27TEST_TYPE = "Server"
28
29# Load and overwrite args_dict.
30args_dict_json = args_dict['args_dict_json']
31args_dict.update(dynamic_suite.byteify(json.loads(args_dict_json)))
32
33# Inject handle to current job instance.
34args_dict['job'] = job
35
36dynamic_suite.reimage_and_run(**args_dict)
37