# Subject/Title: LDT -2174 Treatment Parameters (Create Rx) - SW - 02 - (New Design) - Q&R - 15: SIT - Software Integration Tests - Squish Qt # # Functionalities: Testing all functionalities of Treatment parameters validation mode(Create RX) # # Steps: # 1 Create RX: # - Validate all the values in Create Rx page # - Verify the validate functionality # - Verify the confirm button functionality # - Verify the qr code functionality # - Verfiy the edit button functionality # - Verify the clear all button functionality # - Verify the reject button functionality import names from names import * import squish from leahi_dialin.ui import utils from configuration import config,utility,navigation from leahi_dialin.ui.td_messaging import TD_Messaging from leahi_dialin.common.td_defs import TDOpModes from builtins import int as pyInt from squish import * td = TD_Messaging() def main(): utils.tstStart(__file__) startApplication(utility.aut("-q")) td.td_operation_mode(TDOpModes.MODE_STAN.value) # verify Standby screen test.verify(waitForObjectExists(names.o_standByScreen_MainHome), "In Standby") #click on the HD Mode test.log("Click on the HD Mode") hemodialysis = waitForObject(names.o_createHDTreatment_TouchRect) hemodialysis_btn = utility.findChildByText(hemodialysis, "Hemodialysis") mouseClick(hemodialysis_btn) td.td_Treatment_Parameters_CreateRx(vRejectionReason =0) td.td_operation_mode(TDOpModes.MODE_PRET.value, 0) navigation.navigation_pageIndicator_step(config.CREATERX) mouseClick(squish.waitForObject(names.o_PreTreatmentCreate_pretreatmentPatientIDEntry_TextEntry)) waitForObject(names.o_PreTreatmentCreate_pretreatmentPatientIDEntry_TextEntry).text ="abcd" parent_obj = waitForObject(names.o_PreTreatmentCreate_leftColumn_Column) blood_flow_rate = utility.findObjectById(parent_obj, "_bloodFlowRate") utility.set_value_based_on_target(blood_flow_rate, 60) dialysate_flow_rate = utility.findObjectById(parent_obj, "_dialysateFlowRate") utility.set_value_based_on_target(dialysate_flow_rate, 75) duration = utility.findObjectById(parent_obj,"_duration") utility.set_value_based_on_target(duration, 75) test.log("check the page navigated to create rx page")