Skip to content

Commit 757e5da

Browse files
Qinghao ShiQinghao Shi
authored andcommitted
refactor code to address the failing CI and comments
1 parent ff6b1bc commit 757e5da

File tree

2 files changed

+9
-4
lines changed

2 files changed

+9
-4
lines changed

packages/mbed-greentea/mbed_greentea/mbed_greentea_cli.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -873,7 +873,7 @@ def get_parallel_value(value):
873873

874874
for test_name in filtered_ctest_test_list_keys:
875875
image_path = filtered_ctest_test_list[test_name].get_binary(binary_type=TestBinary.BIN_TYPE_BOOTABLE).get_path()
876-
compare_log = filtered_ctest_test_list[test_name].get_binary(binary_type=TestBinary.BIN_TYPE_BOOTABLE).get_comp_log()
876+
compare_log = filtered_ctest_test_list[test_name].get_binary(binary_type=TestBinary.BIN_TYPE_BOOTABLE).get_compare_log()
877877
if image_path is None:
878878
gt_logger.gt_log_err("Failed to find test binary for test %s flash method %s" % (test_name, 'usb'))
879879
else:

src/mbed_os_tools/test/tests_spec.py

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,8 @@ def get_path(self):
5757
:return:
5858
"""
5959
return self.__path
60-
def get_comp_log(self):
60+
61+
def get_compare_log(self):
6162
"""
6263
Gives compare log file.
6364
:return:
@@ -117,7 +118,9 @@ def parse(self, test_json):
117118
), "Binary spec should contain key [%s]" % ",".join(mandatory_keys)
118119
fm = binary.get(TestBinary.KW_BIN_TYPE, self.__default_flash_method)
119120
assert fm is not None, "Binary type not specified in build and binary spec."
120-
tb = TestBinary(binary[TestBinary.KW_BIN_PATH], fm, binary.get(TestBinary.KW_COMP_LOG))
121+
tb = TestBinary(binary[TestBinary.KW_BIN_PATH],
122+
fm,
123+
binary.get(TestBinary.KW_COMP_LOG))
121124
self.__binaries_by_flash_method[fm] = tb
122125

123126
def add_binary(self, path, binary_type, compare_log=None):
@@ -128,7 +131,9 @@ def add_binary(self, path, binary_type, compare_log=None):
128131
:param binary_type:
129132
:return:
130133
"""
131-
self.__binaries_by_flash_method[binary_type] = TestBinary(path, binary_type, compare_log)
134+
self.__binaries_by_flash_method[binary_type] = TestBinary(path,
135+
binary_type,
136+
compare_log)
132137

133138

134139
class TestBuild:

0 commit comments

Comments
 (0)