Index: tst_create_custom_treatment/test.py =================================================================== diff -u -re8da75c7ba46f21fe99cc7400f3616a715c2ea5e -r72e71415da2be935bc9db69ad887811d917c298d --- tst_create_custom_treatment/test.py (.../test.py) (revision e8da75c7ba46f21fe99cc7400f3616a715c2ea5e) +++ tst_create_custom_treatment/test.py (.../test.py) (revision 72e71415da2be935bc9db69ad887811d917c298d) @@ -1,14 +1,14 @@ # -*- 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_create_custom_treatment -# date 2020/01/27 +# date 2022/01/27 # author Joseph varghese # @@ -31,44 +31,41 @@ def set_parameter_type(text): """ - Method to set object property based on text - @param text : (string) treatment parameter text + Method to set object property based on text + @param text : (string) treatment parameter text """ names.o_operating_parameters["text"] = text return names.o_operating_parameters def prescription_measurement_title(text): """ - Method to set object property based on text - @param text : (string) treatment parameter text + Method to set object property based on text + @param text : (string) treatment parameter text """ names.o_prescription_mesurement["text"] = text return names.o_prescription_mesurement def verify_request_rejection_mode(): """ - Method to verify rejection mode of create custom treatment + Method to verify rejection mode of create custom treatment """ - reject_reasons = [ - RequestRejectReasons.REQUEST_REJECT_REASON_NOT_ALLOWED_IN_CURRENT_MODE - ] * hd_simulator.NUM_TREATMENT_PARAMETERS + reject_reasons = [RequestRejectReasons.REQUEST_REJECT_REASON_NOT_ALLOWED_IN_CURRENT_MODE] * hd_simulator.NUM_TREATMENT_PARAMETERS treatment_status = hd_simulator.cmd_send_treatment_parameter_validation_response(reject_reasons) test.compare(treatment_status, True, "custom treatment should be rejected") def verify_request_continue_mode(): """ - Method to accept treatment response. + Method to accept treatment response. """ mouseClick(waitForObject(names.o_CreateCustomTreatment_Continue_button)) - treatment_status = hd_simulator.cmd_send_treatment_parameter_manual_validation_response([ - 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]) + treatment_status = hd_simulator.cmd_send_treatment_parameter_manual_validation_response([1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]) test.compare(treatment_status, True, "custom treatment should be accepted") def verify_custom_treatment_record_rejected(): """ - Method to verify custom treatment record, if confirmation rejected + Method to verify custom treatment record, if confirmation rejected """ test.startSection("Verifying custom treatment record, if confirmation rejected") @@ -80,15 +77,14 @@ parameter_text = waitForObject(parameter_object) parameter_text_color = parameter_text.color.name - test.compare(expected_color, parameter_text_color, "parameter color should be "\ - "red for " + expected_treatment_title +" , if the confirmation get rejected !") + test.compare(expected_color, parameter_text_color, "parameter color should be ' \red for' " + expected_treatment_title +" , if the confirmation get rejected !") test.endSection() def test_continue_button(): """ - Method to verify continue button of create custom treatment page + Method to verify continue button of create custom treatment page """ test.startSection("Verification of continue button from create custom treatment section") @@ -99,7 +95,7 @@ def test_back_button(): """ - Method to verify back button of create custom treatment page + Method to verify back button of create custom treatment page """ test.startSection("Verification of back button from create custom treatment section") @@ -110,7 +106,7 @@ def create_custom_treatment_record(): """ - Method to set create custom treatment slider value based on slider buffer on negative direction + Method to set create custom treatment slider value based on slider buffer on negative direction """ test.startSection("Method to set create custom treatment slider based on negative slider buffer") @@ -119,19 +115,19 @@ utility.scroll_to_zone(parameter_object, names.o_treatment_create_flickable, direction="Top") #set custom values for parameters - test.startSection("verification of blood flow values") + test.startSection("Verification of blood flow values") test.compare(waitForObject(names.o_PreTreatmentCreate_bloodFlowRate_SliderCreateTreatment).label, config.BLOOD_FLOW_RATE, "Parameter should be -> "+str(config.BLOOD_FLOW_RATE)) for blood_flow_rate in config.CREATE_TREATMENT_PARAMETER_RANGE[config.BLOOD_FLOW_RATE][::-1]: test_custom_treatment_slider(names.o_PreTreatmentCreate_bloodFlowRateSlider_Slider, blood_flow_rate, config.CREATE_TREATMENT_SLIDER_VALUES["blood_flow_rate"], config.BLOOD_FLOW_RATE) test.endSection() - test.startSection("verification of dialysate flow values") + test.startSection("Verification of dialysate flow values") test.compare(waitForObject(names.o_PreTreatmentCreate_dialysateFlowRate_SliderCreateTreatment).label, config.DIALYSATE_FLOW_RATE, "Parameter should be -> "+str(config.DIALYSATE_FLOW_RATE)) for dialysate_flow_rate in config.CREATE_TREATMENT_PARAMETER_RANGE[config.DIALYSATE_FLOW_RATE][::-1]: test_custom_treatment_slider(names.o_PreTreatmentCreate_dialysateFlowRateSlider_Slider, dialysate_flow_rate, config.CREATE_TREATMENT_SLIDER_VALUES["dialysate_flow_rate"], config.DIALYSATE_FLOW_RATE) test.endSection() - test.startSection("verification of duration values") + test.startSection("Verification of duration values") test.compare(waitForObject(names.o_PreTreatmentCreate_duration_SliderCreateTreatment).label, config.DURATION, "Parameter should be -> "+str(config.DURATION)) for duration in config.CREATE_TREATMENT_PARAMETER_RANGE[config.DURATION][::-1]: test_custom_treatment_slider(names.o_PreTreatmentCreate_durationSlider_Slider, duration, config.CREATE_TREATMENT_SLIDER_VALUES["duration"], config.DURATION) @@ -141,14 +137,14 @@ parameter_object = set_parameter_type(text = config.HEPARIN_BOLUS_VOLUME) utility.scroll_to_zone(parameter_object, names.o_treatment_create_flickable) - test.startSection("verification of heparin dispensing rate values") + test.startSection("Verification of heparin dispensing rate values") test.compare(waitForObject(names.o_PreTreatmentCreate_heparinDispensingRate_SliderCreateTreatment).label, config.HEPARIN_DISPENSING_RATE, "Parameter should be -> "+str(config.HEPARIN_DISPENSING_RATE)) for heparin_dispensing_rate in config.CREATE_TREATMENT_PARAMETER_RANGE[config.HEPARIN_DISPENSING_RATE][::-1]: test_custom_treatment_slider(names.o_PreTreatmentCreate_heparinDispensingRateSlider_Slider, heparin_dispensing_rate, config.CREATE_TREATMENT_SLIDER_VALUES["heparin_dispensing_rate"], config.HEPARIN_DISPENSING_RATE) test.compare(config.OFF_TEXT, waitForObject(names.o_PreTreatmentCreate_heparinDispensingRateValue_Text).text, "OFF text should display for value 0") test.endSection() - test.startSection("verification of heparin bolus volume values") + test.startSection("Verification of heparin bolus volume values") test.compare(waitForObject(names.o_PreTreatmentCreate_heparinBolusVolume_SliderCreateTreatment).label, config.HEPARIN_BOLUS_VOLUME, "Parameter should be -> "+str(config.HEPARIN_BOLUS_VOLUME)) for heparin_bolus_volume in config.CREATE_TREATMENT_PARAMETER_RANGE[config.HEPARIN_BOLUS_VOLUME][::-1]: test_custom_treatment_slider(names.o_PreTreatmentCreate_heparinBolusVolumeSlider_Slider, heparin_bolus_volume, config.CREATE_TREATMENT_SLIDER_VALUES["heparin_bolus_volume"], config.HEPARIN_BOLUS_VOLUME) @@ -159,14 +155,14 @@ parameter_object = set_parameter_type(text = config.HEPARIN_TYPE_TITLE) utility.scroll_to_zone(parameter_object, names.o_treatment_create_flickable) - test.startSection("verification of heparin stop time values") + test.startSection("Verification of heparin stop time values") test.compare(waitForObject(names.o_PreTreatmentCreate_heparinStopTime_SliderCreateTreatment).label, config.HEPARIN_STOP_TIME, "Parameter should be -> "+str(config.HEPARIN_STOP_TIME)) for heparin_stop_time in config.CREATE_TREATMENT_PARAMETER_RANGE[config.HEPARIN_STOP_TIME][::-1]: test_custom_treatment_slider(names.o_PreTreatmentCreate_heparinStopTimeSlider_Slider, heparin_stop_time, config.CREATE_TREATMENT_SLIDER_VALUES["heparin_stop_time"], config.HEPARIN_STOP_TIME) test.compare(config.OFF_TEXT, waitForObject(names.o_PreTreatmentCreate_heparinStopTimeValue_Text).text, "OFF text should display for value 0") test.endSection() - test.startSection("verification of saline bolus values") + test.startSection("Verification of saline bolus values") test.compare(waitForObject(names.o_PreTreatmentCreate_salineBolus_SliderCreateTreatment).label, config.SALINE_BOLUS_TITLE, "Parameter should be -> "+str(config.SALINE_BOLUS_TITLE)) for saline_bolus in config.CREATE_TREATMENT_PARAMETER_RANGE[config.SALINE_BOLUS_VOLUME][::-1]: test_custom_treatment_slider(names.o_PreTreatmentCreate_salineBolusSlider_Slider, saline_bolus, config.CREATE_TREATMENT_SLIDER_VALUES["saline_bolus"], config.SALINE_BOLUS_TITLE) @@ -176,7 +172,7 @@ parameter_object = set_parameter_type(text = config.BLOOD_PRESSURE_MEASUREMENT_INTERVAL) utility.scroll_to_zone(parameter_object, names.o_treatment_create_flickable) - test.startSection("verification of dialysate temperature values") + test.startSection("Verification of dialysate temperature values") test.compare(waitForObject(names.o_PreTreatmentCreate_dialysateTemperature_SliderCreateTreatment).label, config.DIALYSATE_TEMPERATURE, "Parameter should be -> "+str(config.DIALYSATE_TEMPERATURE)) for dialysate_temperature in config.CREATE_TREATMENT_PARAMETER_RANGE[config.DIALYSATE_TEMPERATURE][::-1]: test_custom_treatment_slider(names.o_PreTreatmentCreate_dialysateTemperatureSlider_Slider, dialysate_temperature, config.CREATE_TREATMENT_SLIDER_VALUES["dialysate_temperature"], config.DIALYSATE_TEMPERATURE) @@ -189,14 +185,14 @@ #set_arterial_high_and_low_limits_using_slider() set_venous_high_and_low_limits_using_slider() - test.startSection("verification of blood pressure measurement interval values") + test.startSection("Verification of blood pressure measurement interval values") test.compare(waitForObject(names.o_PreTreatmentCreate_bloodPressureMeasurementInterval_SliderCreateTreatment).label, config.BLOOD_PRESSURE_MEASUREMENT_INTERVAL, "Parameter should be -> "+str(config.BLOOD_PRESSURE_MEASUREMENT_INTERVAL)) for blood_pressure_measurement_interval in config.CREATE_TREATMENT_PARAMETER_RANGE[config.BLOOD_PRESSURE_MEASUREMENT_INTERVAL][::-1]: test_custom_treatment_slider(names.o_PreTreatmentCreate_bloodPressureMeasurementIntervalSlider_Slider, blood_pressure_measurement_interval, config.CREATE_TREATMENT_SLIDER_VALUES["blood_pressure_measurement_interval"], config.BLOOD_PRESSURE_MEASUREMENT_INTERVAL) test.compare(config.OFF_TEXT, waitForObject(names.o_PreTreatmentCreate_bloodPressureMeasurementIntervalValue_Text).text, "OFF text should display for value 0") test.endSection() - test.startSection("verification of rinseback flow rate values") + test.startSection("Verification of rinseback flow rate values") parameter_object = set_parameter_type(text = 150) utility.scroll_to_zone(parameter_object, names.o_treatment_create_flickable) test.compare(waitForObject(names.o_PreTreatmentCreate_rinsebackFlowRate_SliderCreateTreatment).label, config.RINSEBACK_FLOW_RATE, "Parameter should be -> "+str(config.RINSEBACK_FLOW_RATE)) @@ -212,18 +208,15 @@ def verify_the_confirm_treatment_screen_is_displayed() -> None: """ - Method to verify confirm treatment title + Method to verify confirm treatment title """ test.log("Verifying the 'Confirm Treatment' is displayed and its title text") confirm_treatment_title = waitForObject(names.o_confirm_title_text) - test.compare(config.CONFIRM_TREATMENT_TITLE, confirm_treatment_title.text.toUtf8().constData(), - config.CONFIRM_TREATMENT_TITLE + " screen is displayed " + - "and title should be " +config.CONFIRM_TREATMENT_TITLE) - + test.compare(config.CONFIRM_TREATMENT_TITLE, confirm_treatment_title.text.toUtf8().constData(), config.CONFIRM_TREATMENT_TITLE + " screen is displayed " +"and title should be " +config.CONFIRM_TREATMENT_TITLE) def verify_prescriptional_details_from_confirm_treatment_screen(): """ - Method to verify prescription details from confirm treatment section. + Method to verify prescription details from confirm treatment section. """ test.startSection("Verifying prescription values from confirm treatment section") verify_the_confirm_treatment_screen_is_displayed() @@ -250,7 +243,7 @@ def verify_operational_details_from_confirm_treatment_screen(): """ - Method to verify operational details from confirm treatment section. + Method to verify operational details from confirm treatment section. """ test.startSection("Verifying operational values from confirm treatment screen") verify_the_confirm_treatment_screen_is_displayed() @@ -269,11 +262,11 @@ def test_custom_treatment_slider(slider_object, value, slider_parameter, parameter): """ - Method to set slider handle based on custom values - @param slider_object : (dictionary) object of treatment parameters - @param vale : (int)value to be set on slider - @param slider_parameter : (list) consist combination of slider minimum value, slider buffer and width buffer - @param parameter : (str) parameter name + Method to set slider handle based on custom values + @param slider_object : (dictionary) object of treatment parameters + @param vale : (int)value to be set on slider + @param slider_parameter : (list) consist combination of slider minimum value, slider buffer and width buffer + @param parameter : (str) parameter name """ minimum_slider_value = slider_parameter[0] slider_buffer = slider_parameter[1] @@ -287,7 +280,7 @@ def set_venous_low_and_high_limits_using_slider(): """ - Method to set the venous low and high limits using slider + Method to set the venous low and high limits using slider """ test.startSection("Set the venous low and high limits using slider") utils.waitForGUI(1) @@ -302,7 +295,7 @@ def set_arterial_low_and_high_limits_using_slider(): """ - Method to set the arterial low and high limits using slider + Method to set the arterial low and high limits using slider """ test.startSection("Set the arterial low and high limits using slider") utils.waitForGUI(1) @@ -316,7 +309,7 @@ def set_venous_high_and_low_limits_using_slider(): """ - Method to set the venous low and high limits using slider + Method to set the venous low and high limits using slider """ test.startSection("Set the venous low and high limits using slider") utils.waitForGUI(1) @@ -330,7 +323,7 @@ def set_arterial_high_and_low_limits_using_slider(): """ - Method to set the arterial low and high limits using slider + Method to set the arterial low and high limits using slider """ test.startSection("Set the arterial low and high limits using slider") utils.waitForGUI(1) @@ -342,11 +335,11 @@ def verify_standby_mode_from_create_treatment(): """ - Method to set slider handle based on custom values - @param slider_object : (dictionary) object of treatment parameters - @param vale : (int)value to be set on slider - @param slider_parameter : (list) consist combination of slider minimum value, slider buffer and width buffer - @param parameter : (str) parameter name + Method to set slider handle based on custom values + @param slider_object : (dictionary) object of treatment parameters + @param vale : (int)value to be set on slider + @param slider_parameter : (list) consist combination of slider minimum value, slider buffer and width buffer + @param parameter : (str) parameter name """ hd_simulator.cmd_send_hd_operation_mode(op_mode = 3) mouseClick(waitForObject(names.o_MainHome_CREATE_TREATMENT_Text)) @@ -359,33 +352,32 @@ type(waitForObject(names.o_input_patient_id), config.PATIENT_ID) test.compare(waitForObject(names.o_PreTreatmentBase_Patient_ID_Text).text, config.PATIENT_ID_TEXT, "Title text should be -> "+str(config.PATIENT_ID_TEXT)) mouseClick(waitForObject(names.o_confirm_button)) - - snooze(5) +# utils.waitForGui(5) def verify_create_custom_treatment_parameter(): """ - Method to set create custom treatment slider value based on slider buffer + Method to set create custom treatment slider value based on slider buffer """ test.startSection("Method to set create custom treatment slider based on positive slider buffer") test.compare(waitForObject(names.o_PreTreatmentCreate_Create_a_Custom_Treatment_Text).text, config.TREATMENT_TITLE, "Title text should be -> "+str(config.TREATMENT_TITLE)) test.compare(waitForObject(names.o_PreTreatmentCreate_PRESCRIPTION_Text).text, config.PRESCRIPTION_TITLE, "Title text should be -> "+str(config.PRESCRIPTION_TITLE)) #set custom values for parameters - test.startSection("verification of blood flow values") + test.startSection("Verification of blood flow values") test.compare(waitForObject(names.o_PreTreatmentCreate_bloodFlowRate_SliderCreateTreatment).label, config.BLOOD_FLOW_RATE, "Parameter should be -> "+str(config.BLOOD_FLOW_RATE)) for blood_flow_rate in config.CREATE_TREATMENT_PARAMETER_RANGE[config.BLOOD_FLOW_RATE]: test_custom_treatment_slider(names.o_PreTreatmentCreate_bloodFlowRateSlider_Slider, blood_flow_rate, config.CREATE_TREATMENT_SLIDER_VALUES["blood_flow_rate"], config.BLOOD_FLOW_RATE) test.endSection() - test.startSection("verification of dialysate flow values") + test.startSection("Verification of dialysate flow values") test.compare(waitForObject(names.o_PreTreatmentCreate_dialysateFlowRate_SliderCreateTreatment).label, config.DIALYSATE_FLOW_RATE, "Parameter should be -> "+str(config.DIALYSATE_FLOW_RATE)) for dialysate_flow_rate in config.CREATE_TREATMENT_PARAMETER_RANGE[config.DIALYSATE_FLOW_RATE]: test_custom_treatment_slider(names.o_PreTreatmentCreate_dialysateFlowRateSlider_Slider, dialysate_flow_rate, config.CREATE_TREATMENT_SLIDER_VALUES["dialysate_flow_rate"], config.DIALYSATE_FLOW_RATE) test.endSection() - test.startSection("verification of duration values") + test.startSection("Verification of duration values") test.compare(waitForObject(names.o_PreTreatmentCreate_duration_SliderCreateTreatment).label, config.DURATION, "Parameter should be -> "+str(config.DURATION)) for duration in config.CREATE_TREATMENT_PARAMETER_RANGE[config.DURATION]: test_custom_treatment_slider(names.o_PreTreatmentCreate_durationSlider_Slider, duration, config.CREATE_TREATMENT_SLIDER_VALUES["duration"], config.DURATION) @@ -395,14 +387,14 @@ parameter_object = set_parameter_type(text = config.HEPARIN_BOLUS_VOLUME) utility.scroll_to_zone(parameter_object, names.o_treatment_create_flickable) - test.startSection("verification of heparin dispensing rate values") + test.startSection("Verification of heparin dispensing rate values") test.compare(waitForObject(names.o_PreTreatmentCreate_heparinDispensingRate_SliderCreateTreatment).label, config.HEPARIN_DISPENSING_RATE, "Parameter should be -> "+str(config.HEPARIN_DISPENSING_RATE)) for heparin_dispensing_rate in config.CREATE_TREATMENT_PARAMETER_RANGE[config.HEPARIN_DISPENSING_RATE]: test_custom_treatment_slider(names.o_PreTreatmentCreate_heparinDispensingRateSlider_Slider, heparin_dispensing_rate, config.CREATE_TREATMENT_SLIDER_VALUES["heparin_dispensing_rate"], config.HEPARIN_DISPENSING_RATE) test.compare(config.OFF_TEXT, waitForObject(names.o_PreTreatmentCreate_heparinDispensingRateValue_Text).text, "OFF text should display for value 0") test.endSection() - test.startSection("verification of heparin bolus volume values") + test.startSection("Verification of heparin bolus volume values") test.compare(waitForObject(names.o_PreTreatmentCreate_heparinBolusVolume_SliderCreateTreatment).label, config.HEPARIN_BOLUS_VOLUME, "Parameter should be -> "+str(config.HEPARIN_BOLUS_VOLUME)) for heparin_bolus_volume in config.CREATE_TREATMENT_PARAMETER_RANGE[config.HEPARIN_BOLUS_VOLUME]: test_custom_treatment_slider(names.o_PreTreatmentCreate_heparinBolusVolumeSlider_Slider, heparin_bolus_volume, config.CREATE_TREATMENT_SLIDER_VALUES["heparin_bolus_volume"], config.HEPARIN_BOLUS_VOLUME) @@ -413,14 +405,14 @@ parameter_object = set_parameter_type(text = config.HEPARIN_TYPE_TITLE) utility.scroll_to_zone(parameter_object, names.o_treatment_create_flickable) - test.startSection("verification of heparin stop time values") + test.startSection("Verification of heparin stop time values") test.compare(waitForObject(names.o_PreTreatmentCreate_heparinStopTime_SliderCreateTreatment).label, config.HEPARIN_STOP_TIME, "Parameter should be -> "+str(config.HEPARIN_STOP_TIME)) for heparin_stop_time in config.CREATE_TREATMENT_PARAMETER_RANGE[config.HEPARIN_STOP_TIME]: test_custom_treatment_slider(names.o_PreTreatmentCreate_heparinStopTimeSlider_Slider, heparin_stop_time, config.CREATE_TREATMENT_SLIDER_VALUES["heparin_stop_time"], config.HEPARIN_STOP_TIME) test.compare(config.OFF_TEXT, waitForObject(names.o_PreTreatmentCreate_heparinStopTimeValue_Text).text, "OFF text should display for value 0") test.endSection() - test.startSection("verification of saline bolus values") + test.startSection("Verification of saline bolus values") test.compare(waitForObject(names.o_PreTreatmentCreate_salineBolus_SliderCreateTreatment).label, config.SALINE_BOLUS_TITLE, "Parameter should be -> "+str(config.SALINE_BOLUS_TITLE)) for saline_bolus in config.CREATE_TREATMENT_PARAMETER_RANGE[config.SALINE_BOLUS_VOLUME]: test_custom_treatment_slider(names.o_PreTreatmentCreate_salineBolusSlider_Slider, saline_bolus, config.CREATE_TREATMENT_SLIDER_VALUES["saline_bolus"], config.SALINE_BOLUS_TITLE) @@ -430,7 +422,7 @@ parameter_object = set_parameter_type(text = config.ACID_CONCENTRATE_TITLE) utility.scroll_to_zone(parameter_object, names.o_treatment_create_flickable) - test.startSection("verification of heparin type") + test.startSection("Verification of heparin type") test.compare(waitForObject(names.o_PreTreatmentCreate_heparinTypeRect_GridSelection).labels, config.HEPARIN_TYPE, "Parameter should be -> "+str(config.HEPARIN_TYPE)) mouseClick(waitForObject(names.o_PreTreatmentCreate_heparinTypeRect0_TouchRect)) test.compare(waitForObject(names.o_PreTreatmentCreate_heparinTypeRect0_TouchRect).text.text, config.HEPARIN_TYPE, "heparin text should be :"+ str(config.HEPARIN_TYPE)) @@ -441,7 +433,7 @@ parameter_object = set_parameter_type(text = config.DIALYZER_TYPE_TITLE) utility.scroll_to_zone(parameter_object, names.o_treatment_create_flickable) - test.startSection("verification of acid concentrate type") + test.startSection("Verification of acid concentrate type") test.compare(waitForObject(names.o_PreTreatmentCreate_acidConcentrateRect_GridSelection).title, config.ACID_CONCENTRATE_TITLE, "Parameter should be -> "+str(config.ACID_CONCENTRATE_TITLE)) mouseClick(names.o_PreTreatmentCreate_acidConcentrateRect0_TouchRect) test.compare(waitForObject(names.o_PreTreatmentCreate_acidConcentrateRect0_TouchRect).bgColor.name, config.TREATMENT_HIGHLIGHTED_COLOR, str(config.HEPARIN_TYPE)+" checkbox should be highlighted") @@ -465,7 +457,7 @@ parameter_object = set_parameter_type(text = config.DIALYZER_TYPE_TITLE) utility.scroll_to_zone(parameter_object, names.o_treatment_create_flickable) - test.startSection("verification of bicarbonate concentrate rectangle") + test.startSection("Verification of bicarbonate concentrate rectangle") test.compare(waitForObject(names.o_PreTreatmentCreate_bicarbonateConcentrateRect_GridSelection).title, config.BICARBONATE_CONCENTRATE_TITLE, "Parameter should be -> "+str(config.BICARBONATE_CONCENTRATE_TITLE)) mouseClick(names.o_PreTreatmentCreate_bicarbonateConcentrateRect0_TouchRect) test.compare(waitForObject(names.o_PreTreatmentCreate_bicarbonateConcentrateRect0_TouchRect).bgColor.name, config.TREATMENT_HIGHLIGHTED_COLOR, str(config.HEPARIN_TYPE)+" checkbox should be highlighted") @@ -476,7 +468,7 @@ parameter_object = set_parameter_type(text = config.DIALYSATE_TEMPERATURE) utility.scroll_to_zone(parameter_object, names.o_treatment_create_flickable) - test.startSection("verification of dialysate rectangle") + test.startSection("Verification of dialysate rectangle") test.compare(waitForObject(names.o_PreTreatmentCreate_dialyzerTypeRect_GridSelection).title, config.DIALYZER_TYPE_TITLE, "Parameter should be -> "+str(config.DIALYZER_TYPE_TITLE)) mouseClick(names.o_PreTreatmentCreate_dialyzerTypeRect0_TouchRect) test.compare(waitForObject(names.o_PreTreatmentCreate_dialyzerTypeRect0_TouchRect).bgColor.name, config.TREATMENT_HIGHLIGHTED_COLOR, str(config.HEPARIN_TYPE)+" checkbox should be highlighted") @@ -503,7 +495,7 @@ parameter_object = set_parameter_type(text = config.BLOOD_PRESSURE_MEASUREMENT_INTERVAL) utility.scroll_to_zone(parameter_object, names.o_treatment_create_flickable) - test.startSection("verification of dialysate temperature values") + test.startSection("Verification of dialysate temperature values") test.compare(waitForObject(names.o_PreTreatmentCreate_dialysateTemperature_SliderCreateTreatment).label, config.DIALYSATE_TEMPERATURE, "Parameter should be -> "+str(config.DIALYSATE_TEMPERATURE)) for dialysate_temperature in config.CREATE_TREATMENT_PARAMETER_RANGE[config.DIALYSATE_TEMPERATURE]: test_custom_treatment_slider(names.o_PreTreatmentCreate_dialysateTemperatureSlider_Slider, dialysate_temperature, config.CREATE_TREATMENT_SLIDER_VALUES["dialysate_temperature"], config.DIALYSATE_TEMPERATURE) @@ -516,14 +508,14 @@ set_arterial_low_and_high_limits_using_slider() set_venous_low_and_high_limits_using_slider() - test.startSection("verification of blood pressure measurement interval values") + test.startSection("Verification of blood pressure measurement interval values") test.compare(waitForObject(names.o_PreTreatmentCreate_bloodPressureMeasurementInterval_SliderCreateTreatment).label, config.BLOOD_PRESSURE_MEASUREMENT_INTERVAL, "Parameter should be -> "+str(config.BLOOD_PRESSURE_MEASUREMENT_INTERVAL)) for blood_pressure_measurement_interval in config.CREATE_TREATMENT_PARAMETER_RANGE[config.BLOOD_PRESSURE_MEASUREMENT_INTERVAL]: test_custom_treatment_slider(names.o_PreTreatmentCreate_bloodPressureMeasurementIntervalSlider_Slider, blood_pressure_measurement_interval, config.CREATE_TREATMENT_SLIDER_VALUES["blood_pressure_measurement_interval"], config.BLOOD_PRESSURE_MEASUREMENT_INTERVAL) test.compare(config.OFF_TEXT, waitForObject(names.o_PreTreatmentCreate_bloodPressureMeasurementIntervalValue_Text).text, "OFF text should display for value 0") test.endSection() - test.startSection("verification of rinseback flow rate values") + test.startSection("Verification of rinseback flow rate values") test.compare(waitForObject(names.o_PreTreatmentCreate_rinsebackFlowRate_SliderCreateTreatment).label, config.RINSEBACK_FLOW_RATE, "Parameter should be -> "+str(config.RINSEBACK_FLOW_RATE)) for rinseback_flow_rate in config.CREATE_TREATMENT_PARAMETER_RANGE[config.RINSEBACK_FLOW_RATE]: test_custom_treatment_slider(names.o_PreTreatmentCreate_rinsebackFlowRateSlider_Slider, rinseback_flow_rate, config.CREATE_TREATMENT_SLIDER_VALUES["rinseback_flow_rate"], config.RINSEBACK_FLOW_RATE) @@ -534,7 +526,7 @@ def create_custom_values_for_treatment(): """ - Method to set create custom treatment slider value based on user input + Method to set create custom treatment slider value based on user input """ test.startSection("Method to set treatment value based on user input") @@ -623,7 +615,6 @@ test.log("Verification of page step indicator from create custom treatment page") utility.verify_page_step_indicator(screen_obj=names.o_PreTreatmentCreate_gridSteps_Grid, treatment_step=PRE_TREATMENT_STEP, treatment_screens=config.PRE_TREATMENT_SCREENS) - verify_create_custom_treatment_parameter() verify_request_rejection_mode() @@ -640,7 +631,6 @@ #set custom values for treatment parameters create_custom_values_for_treatment() - verify_request_continue_mode() #verification of records from confirm treatment screen