Index: tst_DGLoadCellReadingsData/test.py =================================================================== diff -u -r393fd43e9a1cbf6b25a0f107928a051a622b2be2 -r40314c67874695eefc506c3a6a33896495953edd --- tst_DGLoadCellReadingsData/test.py (.../test.py) (revision 393fd43e9a1cbf6b25a0f107928a051a622b2be2) +++ tst_DGLoadCellReadingsData/test.py (.../test.py) (revision 40314c67874695eefc506c3a6a33896495953edd) @@ -13,43 +13,50 @@ # import names -from dialin.squish import utils, denaliMessages +from dialin.ui import utils +from configuration import config, utility - def gotoScreenNtest_Contains_DGLoadCellReadingsData(): - mouseClick(waitForObject(names.o_mainMenu_manager)) + mainMenuManager = utility.get_object_from_names(names.o_mainMenu_manager, "names.o_mainMenu_manager object is missing") + if mainMenuManager is not None: + mouseClick(waitForObject(names.o_mainMenu_manager)) test_values(0, 0, 0, 0) def test_values(vRs1Prim, vRs1Bkup, vRs2Prim, vRs2Bkup): + test.fail("TODO : need to update the text objects to do comparison test...return") + return + test.compare(str(waitForObjectExists(names.o_managerHome_DGLoadCellReadingsData_Rs1Prim).text), "{:.2f}".format(vRs1Prim)) test.compare(str(waitForObjectExists(names.o_managerHome_DGLoadCellReadingsData_Rs1Bkup).text), "{:.2f}".format(vRs1Bkup)) test.compare(str(waitForObjectExists(names.o_managerHome_DGLoadCellReadingsData_Rs2Prim).text), "{:.2f}".format(vRs2Prim)) test.compare(str(waitForObjectExists(names.o_managerHome_DGLoadCellReadingsData_Rs2Bkup).text), "{:.2f}".format(vRs2Bkup)) - +def setDGLoadCellReadingsData(vValue1, vValue2, vValue3, vValue4): + test.fail(f"TODO: need to populate body, used to be denaliMessages.setDGLoadCellReadingsData({vValue1}, {vValue2}, {vValue3}, {vValue4})") + def main(): utils.tstStart(__file__) - startApplication(names.AUT_NAME) + startApplication(config.AUT_NAME) utils.waitForGUI(1) gotoScreenNtest_Contains_DGLoadCellReadingsData() utils.waitForGUI(1) step = 10 for i in range ( 10, 500, step): - denaliMessages.setDGLoadCellReadingsData(i, i + step * 1, i + step * 2, i + step * 3) + setDGLoadCellReadingsData(i, i + step * 1, i + step * 2, i + step * 3) test_values (i, i + step * 1, i + step * 2, i + step * 3) - denaliMessages.setDGLoadCellReadingsData(100, 200, 300, 400) + setDGLoadCellReadingsData(100, 200, 300, 400) test_values (100, 200, 300, 400) - denaliMessages.setDGLoadCellReadingsData(100, 200, 300, 400) + setDGLoadCellReadingsData(100, 200, 300, 400) test_values (100, 200, 300, 400) # Coverage - denaliMessages.setDGLoadCellReadingsData(0, 0, 0, 0) + setDGLoadCellReadingsData(0, 0, 0, 0) test_values (0, 0, 0, 0) utils.tstDone()