|
|
@ -367,7 +367,7 @@ def run_tests(test_list, src_dir, build_dir, exeext, tmpdir, jobs=1, enable_cove
|
|
|
|
def print_results(test_results, max_len_name, runtime):
|
|
|
|
def print_results(test_results, max_len_name, runtime):
|
|
|
|
results = "\n" + BOLD[1] + "%s | %s | %s\n\n" % ("TEST".ljust(max_len_name), "STATUS ", "DURATION") + BOLD[0]
|
|
|
|
results = "\n" + BOLD[1] + "%s | %s | %s\n\n" % ("TEST".ljust(max_len_name), "STATUS ", "DURATION") + BOLD[0]
|
|
|
|
|
|
|
|
|
|
|
|
test_results.sort(key=lambda result: result.name.lower())
|
|
|
|
test_results.sort(key=TestResult.sort_key)
|
|
|
|
all_passed = True
|
|
|
|
all_passed = True
|
|
|
|
time_sum = 0
|
|
|
|
time_sum = 0
|
|
|
|
|
|
|
|
|
|
|
@ -459,6 +459,14 @@ class TestResult():
|
|
|
|
self.time = time
|
|
|
|
self.time = time
|
|
|
|
self.padding = 0
|
|
|
|
self.padding = 0
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def sort_key(self):
|
|
|
|
|
|
|
|
if self.status == "Passed":
|
|
|
|
|
|
|
|
return 0, self.name.lower()
|
|
|
|
|
|
|
|
elif self.status == "Failed":
|
|
|
|
|
|
|
|
return 2, self.name.lower()
|
|
|
|
|
|
|
|
elif self.status == "Skipped":
|
|
|
|
|
|
|
|
return 1, self.name.lower()
|
|
|
|
|
|
|
|
|
|
|
|
def __repr__(self):
|
|
|
|
def __repr__(self):
|
|
|
|
if self.status == "Passed":
|
|
|
|
if self.status == "Passed":
|
|
|
|
color = BLUE
|
|
|
|
color = BLUE
|
|
|
|