From afe1c9532e267a352100ec6785fb4b21ee201528 Mon Sep 17 00:00:00 2001 From: Jacob Boddey Date: Fri, 24 May 2024 14:32:43 +0100 Subject: [PATCH 1/3] Add test count to PDF report --- framework/python/src/common/testreport.py | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/framework/python/src/common/testreport.py b/framework/python/src/common/testreport.py index e2a187cce..80cf84c52 100644 --- a/framework/python/src/common/testreport.py +++ b/framework/python/src/common/testreport.py @@ -63,9 +63,6 @@ def __init__(self, def get_mac_addr(self): return self._mac_addr - def get_mac_addr(self): - return self._mac_addr - def add_module_reports(self, module_reports): self._module_reports = module_reports @@ -97,12 +94,6 @@ def get_report_url(self): def set_mac_addr(self, mac_addr): self._mac_addr = mac_addr - def set_mac_addr(self, mac_addr): - self._mac_addr = mac_addr - - def set_mac_addr(self, mac_addr): - self._mac_addr = mac_addr - def to_json(self): report_json = {} @@ -432,9 +423,9 @@ def generate_footer(self, page_num): def generate_results(self, json_data, page_num): - result_list = ''' + result_list = f'''
-

Results List

+

Results List ({len(self._results)}/{self._total_tests})

Name
Description
From c184d1b0169b0d5bb06641a2911c5949715569e0 Mon Sep 17 00:00:00 2001 From: Jacob Boddey Date: Fri, 24 May 2024 15:12:29 +0100 Subject: [PATCH 2/3] Fix pylint issue --- modules/test/tls/python/src/tls_module.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/test/tls/python/src/tls_module.py b/modules/test/tls/python/src/tls_module.py index 353fc8777..0994d5b22 100644 --- a/modules/test/tls/python/src/tls_module.py +++ b/modules/test/tls/python/src/tls_module.py @@ -119,7 +119,7 @@ def __init__(self, # # cert_table = (f'| Property | Value |\n' # # f'|---|---|\n' # # f"| {'Version':<17} | {version_value:^25} |\n" - # # f"| {'Signature Alg.':<17} | + # # f"| {'Signature Alg.':<17} | # {signature_alg_value:^25} |\n" # # f"| {'Validity from':<17} | {not_before:^25} |\n" # # f"| {'Valid to':<17} | {not_after:^25} |") From 46e12457b08fabfae01b990ff446febc64d2f629 Mon Sep 17 00:00:00 2001 From: Jacob Boddey Date: Thu, 30 May 2024 21:22:32 +0100 Subject: [PATCH 3/3] Exclude error --- framework/python/src/common/testreport.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/framework/python/src/common/testreport.py b/framework/python/src/common/testreport.py index 69ec6d00e..3cf661832 100644 --- a/framework/python/src/common/testreport.py +++ b/framework/python/src/common/testreport.py @@ -423,9 +423,14 @@ def generate_footer(self, page_num): def generate_results(self, json_data, page_num): + successful_tests = 0 + for test in self._results: + if test['result'] != 'Error': + successful_tests += 1 + result_list = f'''
-

Results List ({len(self._results)}/{self._total_tests})

+

Results List ({len(successful_tests)}/{self._total_tests})

Name
Description