Index: tst_CreateTreatment/test.py =================================================================== diff -u -ra0ffac330f006351c100b1c75937eeaa32d70369 -ra3c7851a7de7cbed6b06abef5033b35308c04c93 --- tst_CreateTreatment/test.py (.../test.py) (revision a0ffac330f006351c100b1c75937eeaa32d70369) +++ tst_CreateTreatment/test.py (.../test.py) (revision a3c7851a7de7cbed6b06abef5033b35308c04c93) @@ -1,8 +1,24 @@ # -*- coding: utf-8 -*-" +########################################################################### +# +# Copyright (c) 2020-2026 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) Vy +# @date (last) 01-Dec-2023 +# @author (original) Peter Lucia +# @date (original) 17-Aug-2020 +# +############################################################################ import names -from dialin.squish import utils +from configuration import config, utility +from dialin.ui import utils from dialin.common.msg_defs import RequestRejectReasons from dialin import HDSimulator from time import sleep @@ -60,19 +76,23 @@ @return: None """ + + createTreatmentButton = utility.get_object_from_names(names.o_create_treatment_button, "names.o_create_treatment_button object missing") + if createTreatmentButton is not None: + mouseClick(waitForObject(names.o_create_treatment_button)) + utils.waitForGUI(0.5) - mouseClick(waitForObject(names.o_create_treatment_button)) - utils.waitForGUI(0.5) + test.compare(waitForObject(names.o_create_treatment_flickable).visible, True, "Create treatment page loads") - test.compare(waitForObject(names.o_create_treatment_flickable).visible, True, "Create treatment page loads") - def test_parameters_exist(): """ Tests that all treatment parameter components exist on the treatment parameters page. @return: None """ - + test.fail("TODO : test_parameters_exist() Need to update / remove the testcase to reflect new GUIs and navigation...return") + return + parameter_names = { "_bloodFlowRate": "SliderCreateTreatment", "_dialysateFlowRate": "SliderCreateTreatment", @@ -110,7 +130,9 @@ @return: None """ - + test.fail("TODO : test_sliders() Need to update / remove the testcase to reflect new GUIs and navigation...return") + return + sliders = { "_bloodFlowRate": {"min": slider_ranges["bloodFlowRateMin"], "max": slider_ranges["bloodFlowRateMax"], "units": "mL/min" }, "_dialysateFlowRate": {"min": slider_ranges["dialysateFlowRateMin"], "max": slider_ranges["dialysateFlowRateMax"], "units": "mL/min" }, @@ -199,6 +221,8 @@ @return: None """ + test.fail("TODO : test_rects() Need to update / remove the testcase to reflect new GUIs and navigation...return") + return flick(waitForObject(names.o_create_treatment_flickable), 0, -1100) @@ -239,6 +263,9 @@ @param hd_simulator: the HDSimulator object @return: None """ + test.fail("TODO : Need to update / remove the testcase to reflect new GUIs and navigation...return") + return + utils.waitForGUI(0.5) flick(waitForObject(names.o_create_treatment_flickable), 0, 2000) @@ -266,14 +293,17 @@ @param hd_simulator: the HDSimulator object @return: None """ + test.fail("TODO : test_continue_success() Need to update / remove the testcase to reflect new GUIs and navigation...return") + return + flick(waitForObject(names.o_create_treatment_flickable), 0, 700) mouseClick(waitForObject(names.o_create_treatment_continue)) sleep(1) test.compare(waitForObjectExists(names.o_create_treatment_confirm).visible, True) def main(): utils.tstStart(__file__) - startApplication(names.AUT_NAME + " -q") + startApplication(config.AUT_NAME + " -q") hd_simulator = HDSimulator() test_load_create_treatment() test_continue_failure(hd_simulator)