Index: shared/scripts/configuration/utility.py =================================================================== diff -u -re074ab4641bebc4796543ddaeeb7afae5411e77d -r08f868c7ceea6a586e4c78c30529a2100f6999bd --- shared/scripts/configuration/utility.py (.../utility.py) (revision e074ab4641bebc4796543ddaeeb7afae5411e77d) +++ shared/scripts/configuration/utility.py (.../utility.py) (revision 08f868c7ceea6a586e4c78c30529a2100f6999bd) @@ -11,7 +11,7 @@ # @date (last) 15-Jan-2022 # ############################################################################ - + import names import sys import test @@ -171,7 +171,7 @@ raise LookupError("zone object is not in view to the user after " + \ "trying 100 times") - + def get_alarm_id_obj(id): names.o_alarm_id["text"] = id return names.o_alarm_id @@ -181,8 +181,8 @@ return names.o_alarm_message def rejection_msg(text): - names.rejection_msg["text"] = text - return names.rejection_msg + names.o_rejection_msg["text"] = text + return names.o_rejection_msg def set_slider_value(slider_value= None, slider_object= None, bidirectional= False, slider_range = None): Index: shared/scripts/names.py =================================================================== diff -u -re074ab4641bebc4796543ddaeeb7afae5411e77d -r08f868c7ceea6a586e4c78c30529a2100f6999bd --- shared/scripts/names.py (.../names.py) (revision e074ab4641bebc4796543ddaeeb7afae5411e77d) +++ shared/scripts/names.py (.../names.py) (revision 08f868c7ceea6a586e4c78c30529a2100f6999bd) @@ -204,6 +204,7 @@ o_dialysate_flow_minimum_value = {"container": o_Overlay, "text": "0mL/min", "type": "Text", "unnamed": 1, "visible": True} o_dialysate_flow_maximum_value = {"container": o_Overlay, "occurrence": 2, "text": "0mL/min", "type": "Text", "unnamed": 1, "visible": True} o_handler_Rectangle = {"container": o_Overlay, "gradient": 0, "id": "_handler", "type": "Rectangle", "unnamed": 1, "visible": True} +o_treatment_saline_notification_msg = {"container": o_treatmentHome, "id": "_text", "type": "Text", "unnamed": 1, "visible": True} #vitals Index: tst_treatment_saline_data/test.py =================================================================== diff -u -rcfb90b69e9a9d77bbaed7c8a33ce177ca5dd29df -r08f868c7ceea6a586e4c78c30529a2100f6999bd --- tst_treatment_saline_data/test.py (.../test.py) (revision cfb90b69e9a9d77bbaed7c8a33ce177ca5dd29df) +++ tst_treatment_saline_data/test.py (.../test.py) (revision 08f868c7ceea6a586e4c78c30529a2100f6999bd) @@ -20,7 +20,7 @@ from dialin.ui.hd_simulator import HDSimulator from dialin.common.ui_defs import TXStates as txStates from dialin.common.msg_defs import RequestRejectReasons as rejectReason -from configuration import config +from configuration import config, utility #testing options for main treatment saline SALINE_BOLUS_TARGET = [0, 1, 25, 30, 50, 80, 70, 150, 180, 220, 250, 280, 300] @@ -96,7 +96,7 @@ # when rejected reason set 16 -> saline bolus in progress if (not accept_status): rejection_reason = rejectReason.REQUEST_REJECT_REASON_SALINE_BOLUS_IN_PROGRESS.value hd_simulator.cmd_set_saline_bolus_response(accepted = accept_status, reason = rejection_reason, target = target) - if (not accept_status): test.compare(findObject(names.o_treatment_notification_bar).text, config.REJECTION_REASON[rejection_reason], \ + if (not accept_status): test.compare(waitForObjectExists(utility.rejection_msg(config.REJECTION_REASON[rejection_reason])).text, config.REJECTION_REASON[rejection_reason], \ "expected rejection {msg} displayed".format(msg=config.REJECTION_REASON[rejection_reason])) #set saline transition state. @@ -119,7 +119,7 @@ test.startSection("verification of rejection messages on saline bolus") for rejection in range(1, config.NUM_OF_REQUEST_REJECT_REASONS): hd_simulator.cmd_set_saline_bolus_response(accepted = accept_status, reason = rejection, target = target) - rejection_message = findObject(names.o_treatment_notification_bar) + rejection_message = waitForObjectExists(utility.rejection_msg(config.REJECTION_REASON[rejection])) test.compare(rejection_message.text, config.REJECTION_REASON[rejection], "expected rejection {msg} displayed".format(msg=config.REJECTION_REASON[rejection])) test.endSection()