ci: pass target from build stage to unit test
This commit is contained in:
committed by
Angus Gratton
parent
4558824150
commit
3a9ae4acc6
@@ -19,13 +19,12 @@ except ImportError:
|
||||
|
||||
|
||||
class Group(CIAssignTest.Group):
|
||||
SORT_KEYS = ["config", "SDK", "test environment", "multi_device", "multi_stage", "tags"]
|
||||
SORT_KEYS = ["config", "test environment", "multi_device", "multi_stage", "tags", "chip_target"]
|
||||
MAX_CASE = 30
|
||||
ATTR_CONVERT_TABLE = {
|
||||
"execution_time": "execution time"
|
||||
}
|
||||
# when IDF support multiple chips, SDK will be moved into tags, we can remove it
|
||||
CI_JOB_MATCH_KEYS = ["test environment", "SDK"]
|
||||
CI_JOB_MATCH_KEYS = ["test environment"]
|
||||
|
||||
def __init__(self, case):
|
||||
super(Group, self).__init__(case)
|
||||
@@ -84,6 +83,7 @@ class Group(CIAssignTest.Group):
|
||||
:return: {"Filter": case filter, "CaseConfig": list of case configs for cases in this group}
|
||||
"""
|
||||
test_function = self._map_test_function()
|
||||
|
||||
output_data = {
|
||||
# we don't need filter for test function, as UT uses a few test functions for all cases
|
||||
"CaseConfig": [
|
||||
@@ -91,8 +91,26 @@ class Group(CIAssignTest.Group):
|
||||
"name": test_function,
|
||||
"extra_data": self._create_extra_data(test_function),
|
||||
}
|
||||
]
|
||||
],
|
||||
}
|
||||
|
||||
target = self._get_case_attr(self.case_list[0], "chip_target")
|
||||
if target is not None:
|
||||
target_dut = {
|
||||
"esp32": "ESP32DUT",
|
||||
"esp32s2beta": "ESP32S2DUT",
|
||||
"esp8266": "ESP8266DUT",
|
||||
}[target]
|
||||
output_data.update({
|
||||
"Filter": {
|
||||
"overwrite": {
|
||||
"dut": {
|
||||
"path": "IDF/IDFDUT.py",
|
||||
"class": target_dut,
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
return output_data
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user