Index: suite_leahi/shared/scripts/configuration/config.py =================================================================== diff -u -r54d08dd3742f9df060349908b004753da1c8bcc4 -r57c9777c3d6cf91c6a3bb03a4d3f65098997e4fc --- suite_leahi/shared/scripts/configuration/config.py (.../config.py) (revision 54d08dd3742f9df060349908b004753da1c8bcc4) +++ suite_leahi/shared/scripts/configuration/config.py (.../config.py) (revision 57c9777c3d6cf91c6a3bb03a4d3f65098997e4fc) @@ -3,6 +3,8 @@ # -K, --enable-acknow-log Enables Acknowledgment Log AUT_NAME = "leahi -k -K -S -q" +AUT_NAME_ONLY = "leahi" +AUT_PATH = "/home/denali/Leahi-AUT/leahi" # Configuration application_init.py TMP_DIR = "/tmp/" @@ -22,3 +24,36 @@ "OS Version", "UI Version", "TD Version", "TD FPGA Version", "TD Serial Number", "DD Version", "DD FPGA Version", "DD Serial Number", ] + +#Device Settings Information Version +INFORMATION_SCREEN_TITLE_TEXT = "Information" +INFORMATION_TITLES = ["Information", "Versions"] +VERSION_PARAMETERS = [ + "Information", "UI Version", "TD Version", "TD FPGA Version", + "TD Serial Number", "DD Version", "DD FPGA Version", "DD Serial Number" +] +SERVICES_PARAMETERS = [ + "TD Last Service Date", "TD Next Service Date", + "DD Last Service Date", "DD Next Service Date" +] +SERIVCES_TITLE = "Service" +WATER_PARAMETERS = ["Water Configuration", "Water Input"] + +# General Alarm Requirements Instruction +NUM_OF_ALARM_PRIORITIES = 4 # Total number of alarm priorities +ALARM_MUTE_FLAG = 0B0000001000000000 +ALARM_UNMUTE_FLAG = 0B0000000000000000 +ALARM_PRIORITY_OPTIONS = { + 0 : 'ALARM_PRIORITY_NONE' , + 1 : 'ALARM_PRIORITY_LOW' , + 2 : 'ALARM_PRIORITY_MEDIUM', + 3 : 'ALARM_PRIORITY_HIGH', +} + +ALARMS_COLORS_HEADER = { + "ALARM_PRIORITY_NONE" : "#438feb", + "ALARM_PRIORITY_LOW" : "#db8f00", + "ALARM_PRIORITY_MEDIUM" : "#db8f00", + "ALARM_PRIORITY_HIGH" : "#c53b33" +} +ALARM_REJECT_NOTIFICATION_TEMPLATE = "No Active Alarm List [{}]" Index: suite_leahi/tst_headerbar_information_popup/test.py =================================================================== diff -u -r2eb99d3d5db7c53fca759d79b73a096682c5c3e5 -r57c9777c3d6cf91c6a3bb03a4d3f65098997e4fc --- suite_leahi/tst_headerbar_information_popup/test.py (.../test.py) (revision 2eb99d3d5db7c53fca759d79b73a096682c5c3e5) +++ suite_leahi/tst_headerbar_information_popup/test.py (.../test.py) (revision 57c9777c3d6cf91c6a3bb03a4d3f65098997e4fc) @@ -12,6 +12,7 @@ # 7 Set and Compare Information Parameters at their values Below the Minimum Allowed import names +import subprocess from configuration import config from leahi_dialin.ui.td_messaging import TD_Messaging from leahi_dialin.ui import utils @@ -60,6 +61,22 @@ return None +def get_aut_version(aut_path): + """ + Executes the AUT with the --version argument and captures the output. + """ + command = [aut_path, "--version"] + # Running the command and capturing the output. + result = subprocess.run( + command, + capture_output=True, + text=True, + ) + aut_name_and_version = result.stdout.strip() + aut_version = aut_name_and_version.split(" ") + aut_version_only = aut_version[1] + return aut_version_only + def verify_td_and_dd_versions( td_major, td_minor, @@ -127,10 +144,12 @@ compatibility_rev = dd_compatibility_rev ) dd_simulator.dd_serial(dd_serial) + + ui_version = get_aut_version(config.AUT_PATH) version_details = { "OS Version" : "123.123.123.20230628230011", - "UI Version" : "staging-09241954-0", + "UI Version" : ui_version, "TD Version" : None, "TD FPGA Version" : None, "TD Serial Number": None,