Index: tst_end_treatment/test.py =================================================================== diff -u -r7509f73c732db5baebb989bd9e9bd6a3faeec0bc -r316fd2f51b0fa89c0f69949d79ef246e1e4bc4ed --- tst_end_treatment/test.py (.../test.py) (revision 7509f73c732db5baebb989bd9e9bd6a3faeec0bc) +++ tst_end_treatment/test.py (.../test.py) (revision 316fd2f51b0fa89c0f69949d79ef246e1e4bc4ed) @@ -1,27 +1,26 @@ # -*- coding: utf-8 -*-" - -## -# Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. -# copyright -# THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, -# IN PART OR IN WHOLE, -# WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. +########################################################################### # -# file tst_post_treatment_disconnection -# date 2022/06/06 -# author Amol Shinde -# author Shweta POlicepatil -# author Amrita Debnath -# author Ajina S M -# NOTE: -# This test contradicts verification of post treatment section. +# Copyright (c) 2022-2025 Diality Inc. - All Rights Reserved. +# +# THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN +# WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. +# +# @file test.py +# +# @author (last) denali +# @date (last) 13-Nov-2024 +# @author (original) Shweta Policepatil +# @date (original) 08-Jun-2022 +# +############################################################################ import names from dialin.ui import utils from dialin.ui.hd_simulator import HDSimulator from configuration import config from configuration import utility -from dialin.common.hd_defs import TreatmentStates, TreatmentEndStates +from dialin.common.hd_defs import TreatmentStates, TreatmentEndStates, BloodLeakZeroingStates hd_simulator = HDSimulator() @@ -30,9 +29,17 @@ Method to verify End treatment Treatment Complete state screens """ test.startSection("Verifying End treatment Treatment Complete state screens") - hd_simulator.cmd_set_treatment_states_data(sub_mode= TreatmentStates.TREATMENT_END_STATE.value , uf_state = TreatmentStates.TREATMENT_START_STATE.value, - saline_state = TreatmentStates.TREATMENT_START_STATE.value, heparin_state = TreatmentStates.TREATMENT_START_STATE.value,rinseback_state= TreatmentStates.TREATMENT_START_STATE.value, recirculate_state = TreatmentStates.TREATMENT_START_STATE.value, - blood_prime_state = TreatmentStates.TREATMENT_START_STATE.value,treatment_end_state = TreatmentStates.TREATMENT_START_STATE.value, treatment_stop_state = TreatmentStates.TREATMENT_START_STATE.value, dialysis_state = TreatmentStates.TREATMENT_START_STATE.value) + hd_simulator.cmd_set_treatment_states_data(sub_mode= TreatmentStates.TREATMENT_END_STATE.value, + uf_state = TreatmentStates.TREATMENT_START_STATE.value, + saline_state = TreatmentStates.TREATMENT_START_STATE.value, + heparin_state = TreatmentStates.TREATMENT_START_STATE.value, + rinseback_state= TreatmentStates.TREATMENT_START_STATE.value, + recirculate_state = TreatmentStates.TREATMENT_START_STATE.value, + blood_prime_state = TreatmentStates.TREATMENT_START_STATE.value, + treatment_end_state = TreatmentStates.TREATMENT_START_STATE.value, + treatment_stop_state = TreatmentStates.TREATMENT_START_STATE.value, + dialysis_state = TreatmentStates.TREATMENT_START_STATE.value, + bloodLeakZeoringState = BloodLeakZeroingStates.BLD_ZEROING_IDLE_STATE.value) test.compare(str(waitForObject(names.o_end_treatment_complete_state).text),config.END_TREATMENT_COMPLETE_STATE_TEXT, "Treatment text must be {}".format(config.END_TREATMENT_COMPLETE_STATE_TEXT)) test.compare(str(waitForObjectExists(names.o_start_rinseback_button_text).text), config.RINSEBACK_BUTTON_TEXT, "Rinseback button text must be {}".format(config.RINSEBACK_BUTTON_TEXT)) @@ -46,9 +53,17 @@ Method to verify End treatment Treatment Paused state screens """ test.startSection("Verifying End treatment Treatment Paused state screens") - hd_simulator.cmd_set_treatment_states_data(sub_mode=TreatmentStates.TREATMENT_END_STATE.value, uf_state=TreatmentStates.TREATMENT_START_STATE.value, - saline_state=TreatmentStates.TREATMENT_START_STATE.value, heparin_state=TreatmentStates.TREATMENT_START_STATE.value, rinseback_state=TreatmentStates.TREATMENT_START_STATE.value, recirculate_state=TreatmentStates.TREATMENT_START_STATE.value, - blood_prime_state=TreatmentStates.TREATMENT_START_STATE.value, treatment_end_state=TreatmentEndStates.TREATMENT_END_PAUSED_STATE.value, treatment_stop_state=TreatmentStates.TREATMENT_START_STATE.value, dialysis_state=TreatmentStates.TREATMENT_START_STATE.value) + hd_simulator.cmd_set_treatment_states_data(sub_mode=TreatmentStates.TREATMENT_END_STATE.value, + uf_state=TreatmentStates.TREATMENT_START_STATE.value, + saline_state=TreatmentStates.TREATMENT_START_STATE.value, + heparin_state=TreatmentStates.TREATMENT_START_STATE.value, + rinseback_state=TreatmentStates.TREATMENT_START_STATE.value, + recirculate_state=TreatmentStates.TREATMENT_START_STATE.value, + blood_prime_state=TreatmentStates.TREATMENT_START_STATE.value, + treatment_end_state=TreatmentEndStates.TREATMENT_END_PAUSED_STATE.value, + treatment_stop_state=TreatmentStates.TREATMENT_START_STATE.value, + dialysis_state=TreatmentStates.TREATMENT_START_STATE.value, + bloodLeakZeoringState = BloodLeakZeroingStates.BLD_ZEROING_IDLE_STATE.value) test.compare(str(waitForObject(names.o_end_treatment_complete_paused_state).text), config.END_TREATMENT_COMPLETE_PAUSED_STATE_TEXT, "Treatment text must be {}".format(config.END_TREATMENT_COMPLETE_PAUSED_STATE_TEXT)) test.endSection()