Index: tst_post/test.py =================================================================== diff -u -reabfecc1d8d205f4b8888b99158c54f5ac92ae4e -r18f9bc4c23e5b97b187c14132a8cd7c669f0bf58 --- tst_post/test.py (.../test.py) (revision eabfecc1d8d205f4b8888b99158c54f5ac92ae4e) +++ tst_post/test.py (.../test.py) (revision 18f9bc4c23e5b97b187c14132a8cd7c669f0bf58) @@ -6,8 +6,8 @@ # WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. # # file tst_post -# date 03/17/2022 -# author Papiya Mandal +# @author (last) Papiya Mandal +# @date (last) 22-03-2022 # import names @@ -43,16 +43,14 @@ def verify_the_progress(value, final_msg_posted) -> None: """ Method to verify the progress - @param value: int single message + @param value - (int) single message + @final_msg_posted - (bool) True/False """ - progress = pyInt(get_progress())-1 + progress = pyInt(get_progress()) if final_msg_posted is True: - test.xcompare(value, progress, "Final value " + - "{value} should ".format(value=value) + - "not reflect on the progress bar") + test.xcompare(value, progress, "Final value {} should not reflect on the progress bar".format(value)) elif final_msg_posted is False: - test.compare(value, progress, "{value}".format(value=value) + - " should reflect on progress bar") + test.compare(value, progress, "{} should reflect on progress bar".format(value)) def post_a_message_and_verify_progress_and_completion(msgs_and_conditions): @@ -64,7 +62,7 @@ final_msg = conditions[0] final_msg_posted = conditions[1] hd.cmd_send_hd_post(msg, final_msg, final_msg_posted) - utils.waitForGUI(2) + utils.waitForGUI(1) verify_the_progress(value=msg, final_msg_posted=final_msg_posted) verify_final_message_posted(final_msg=final_msg, final_msg_posted=final_msg_posted) @@ -73,8 +71,8 @@ """ method to verify the indication of final message posted - @param final_msg: bool final message(True/False) - @param final_msg_posted: bool if this is the final post message(True/False) + @param final_msg - (bool) final message(True/False) + @param final_msg_posted - (bool) if this is the final post message(True/False) @return: None """ test.startSection("Verifying the status") @@ -90,8 +88,7 @@ fail_indicator = waitForObject(names.o_fail_indicator) test.compare(fail_indicator.enabled, True, "Failed, Final value not passed") - elif (final_msg == True and final_msg_posted == False)\ - or (final_msg == False and final_msg_posted == False): + elif (final_msg == True and final_msg_posted == False) or (final_msg == False and final_msg_posted == False): if object.exists(names.o_busy_indicator): busy_indicator = waitForObject(names.o_busy_indicator) @@ -107,7 +104,5 @@ hd.cmd_send_power_on_self_test_version_request() post_a_message_and_verify_progress_and_completion(MSGS_AND_CONDITIONS) - utils.waitForGUI(2) - utils.tstDone()