xref: /aosp_15_r20/external/autotest/autotest_lib/test_suites/control.cts_hardware (revision 9c5db1993ded3edbeafc8092d69fe5de2ee02df7)
1# Copyright 2018 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 = "[email protected]"
6NAME = "cts-hardware"
7PURPOSE = "Special hardware only test-suite for ARC++ CTS qualification."
8CRITERIA = "All tests with SUITE=cts-hardware must pass."
9
10TIME = "LONG"
11TEST_CATEGORY = "General"
12TEST_CLASS = "suite"
13TEST_TYPE = "Server"
14
15DOC = """
16ChromeOS ARC++ tests.
17"""
18
19import common
20from autotest_lib.server.cros.dynamic_suite import dynamic_suite
21
22def predicate(test):
23  if not hasattr(test, 'suite') or not hasattr(test, 'name'):
24    return False
25  if not NAME in test.suite.split(','):
26    return False
27  # Strip off the cheets_CTS. from the test name before comparing to args
28  name = test.name[test.name.find('.') + 1:]
29  # Typical examples:
30  #   name = 'arm.CtsDeqpTestCases.64'
31  #     or
32  #   name = 'x86.CtsDeqpTestCases.32.ctshardware'
33  # and
34  #   args_dict['tests'] = ['arm.CtsDeqpTestCases', 'x86.CtsDeqpTestCases']
35  # So, we want to includes test with names being subpart of any arg.
36  if 'tests' in args_dict and all(arg not in name for arg in args_dict['tests']):
37    return False
38  return True
39
40args_dict['name'] = NAME
41args_dict['job'] = job
42args_dict['file_bugs'] = False
43args_dict['max_runtime_mins'] = 10080
44args_dict['timeout_mins'] = 10080
45args_dict['add_experimental'] = True
46args_dict['predicate'] = predicate
47dynamic_suite.reimage_and_run(**args_dict)
48
49