Index: suite_leahi/shared/scripts/configuration/config.py =================================================================== diff -u -rb6aa1adafbc0b279e012c904ecde7774fb0000ea -rf89e67f8f2dd341d78381fb45b42ee2d53f242e0 --- suite_leahi/shared/scripts/configuration/config.py (.../config.py) (revision b6aa1adafbc0b279e012c904ecde7774fb0000ea) +++ suite_leahi/shared/scripts/configuration/config.py (.../config.py) (revision f89e67f8f2dd341d78381fb45b42ee2d53f242e0) @@ -92,5 +92,5 @@ NEXT ="Next" ISOLATED_UF_VOLUME_REMOVED = "Isolated UF Volume Removed" ISOLATED_UF_VOLUME_GOAL ="Isolated UF Volume Goal" - - +ULTRAFILTRATION_PAUSED_STATE = "Ultrafiltration Paused" +ULTRAFILTRATION_COMPLETE_STATE = "Ultrafiltration Complete" Index: suite_leahi/shared/scripts/names.py =================================================================== diff -u -rb6aa1adafbc0b279e012c904ecde7774fb0000ea -rf89e67f8f2dd341d78381fb45b42ee2d53f242e0 --- suite_leahi/shared/scripts/names.py (.../names.py) (revision b6aa1adafbc0b279e012c904ecde7774fb0000ea) +++ suite_leahi/shared/scripts/names.py (.../names.py) (revision f89e67f8f2dd341d78381fb45b42ee2d53f242e0) @@ -96,6 +96,13 @@ o_backButton_BackButton = {"container": o_Overlay, "id": "_backButton", "type": "BackButton", "unnamed": 1 } o_notificationBar_NotificationBarSmall = {"container": o_Overlay, "objectName": "NotificationBar", "type": "NotificationBarSmall" } o_title_Text = {"container": o_Overlay, "type": "Text", "unnamed": 1 } +o_ufVolumeGoal = {"container": o_Overlay, "objectName": "_ufVolumeGoal", "type": "LabelUnitText", } +o_ufRate = {"container": o_Overlay, "objectName": "_ufRate", "type": "LabelUnitText", } +o_ultrafiltration_pauseResumeButton_TouchRect = {"container": o_Overlay, "objectName": "_pauseResumeButton", "type": "TouchRect", } +o_PopupItem = {"container": o_Overlay, "type": "PopupItem", "unnamed": 1 } +o_treatmentHome_ultrafiltration_status = {"container": mainTreatmentScreen, "id": "_statusItem", "type": "Item", "unnamed": 1 } +o_Popup_CloseButton = {"container": o_Overlay, "id": "_closeButton", "type": "CloseButton", "unnamed": 1 } + # Device Settings Information Version o_DeviceSettingsInformation = {"container": o_SettingsHome, "id": "_touchItem", "type": "TouchRect", "unnamed": 1 } @@ -252,8 +259,3 @@ o_rate_LabelUnitText = {"container": o_Overlay, "objectName": "_rate", "type": "LabelUnitText" } o_treatmentAdjustmentIsolatedUFDurationEdit = {"container": o_Overlay, "objectName": "_treatmentAdjustmentIsolatedUFDurationEdit", "type": "TreatmentAdjustmentIsolatedUFDurationEdit" } o_treatmentAdjustmentIsolatedUFVolumeEdit = {"container": o_Overlay, "objectName": "_treatmentAdjustmentIsolatedUFVolumeEdit", "type": "TreatmentAdjustmentIsolatedUFVolumeEdit" } - - - - - Index: suite_leahi/tst_ultrafiltration/test.py =================================================================== diff -u -r1dac9e893080fac22c380d2d0f619e39cea2ba59 -rf89e67f8f2dd341d78381fb45b42ee2d53f242e0 --- suite_leahi/tst_ultrafiltration/test.py (.../test.py) (revision 1dac9e893080fac22c380d2d0f619e39cea2ba59) +++ suite_leahi/tst_ultrafiltration/test.py (.../test.py) (revision f89e67f8f2dd341d78381fb45b42ee2d53f242e0) @@ -12,8 +12,10 @@ # 7 Check the New UF Volume and New UF rate values in Confirm Ultrafiltration popup # 8 Check the back button functionality in the popup screen # 9 Check the rejection reason message in the popup screen +#10 Comparison of Ultrafiltration Paused State and Ultrafiltration Complete State texts + import names from configuration import utility @@ -92,8 +94,51 @@ test.compare(waitForObjectExists(names.o_uf_Rate_LabelValue).bottomText, "{:.2f}".format(float(uf_rate)), "UF Rate value should be :" + str(uf_rate)) test.compare(waitForObjectExists(names.o_volume_Delivered).text, "{:.2f}".format(float(volume_delivered)) +" L", "Volume delivered value should be :" + str(volume_delivered)) - +def ultrfiltration_paused_completed_state(): + """ + Comparison of Ultrafiltration Paused State and Ultrafiltration Complete State texts + """ + mouseClick(waitForObject(names.o_editButton_ultrafiltration_IconButton, 2000)) + mouseClick(waitForObject(names.o_ultrafiltration_pauseResumeButton_TouchRect, 2000)) + td.td_ultrafiltration(10, 0.53, 0.37, 1) + notification_row_object = waitForObjectExists(names.o_PopupItem, 3000) + ultrafiltration_paused_state = utility.findChildByText( + notification_row_object, config.ULTRAFILTRATION_PAUSED_STATE + ) + test.compare( + ultrafiltration_paused_state.text, + config.ULTRAFILTRATION_PAUSED_STATE, + "Comparison Ultrafiltration Paused State text in Ultrafiltration popup", + ) + mouseClick(waitForObject(names.o_Popup_CloseButton, 3000)) + + ultrafiltration_status_object = waitForObjectExists( + names.o_treatmentHome_ultrafiltration_status, 3000 + ) + ultrafiltration_paused_state = utility.findChildByText( + ultrafiltration_status_object, config.ULTRAFILTRATION_PAUSED_STATE + ) + test.compare( + ultrafiltration_paused_state.text, + config.ULTRAFILTRATION_PAUSED_STATE, + "Comparison Ultrafiltration Paused State text in Main Treatment Screen", + ) + + td.td_ultrafiltration(10, 0.53, 10, 0) + ultrafiltration_status_object = waitForObjectExists( + names.o_treatmentHome_ultrafiltration_status, 3000 + ) + ultrafiltration_complete_state = utility.findChildByText( + ultrafiltration_status_object, config.ULTRAFILTRATION_COMPLETE_STATE + ) + test.compare( + ultrafiltration_complete_state.text, + config.ULTRAFILTRATION_COMPLETE_STATE, + "Comparison Ultrafiltration Complete State text in Main Treatment Screen", + ) + + def main(): utils.tstStart(__file__) @@ -196,6 +241,13 @@ REJECT_TEXT = repo.get("1", "Title") test.compare(reject_text,"[1] "+REJECT_TEXT ,"Text should be ->" +str(REJECT_TEXT)) test.endSection() + + test.startSection( + "Comparison of Ultrafiltration Paused State and Ultrafiltration Complete State texts" + ) + ultrfiltration_paused_completed_state() + test.endSection() + utils.tstDone()