Index: suite_leahi/shared/scripts/configuration/utility.py =================================================================== diff -u -r17a6f169534356e32110542fb0221cf58d6a09f7 -rd110c822fb709cc77d0cfb48c52bca4be3a6c0c6 --- suite_leahi/shared/scripts/configuration/utility.py (.../utility.py) (revision 17a6f169534356e32110542fb0221cf58d6a09f7) +++ suite_leahi/shared/scripts/configuration/utility.py (.../utility.py) (revision d110c822fb709cc77d0cfb48c52bca4be3a6c0c6) @@ -20,29 +20,8 @@ test.fail("ERROR : " + error_message) return None -def get_bullet_object(screen_obj, num): +def set_Object_Text(text,obj): """ - To obtain a bullet object based on occurrence provided. - @param screen_obj: provides the container on which the bullet must be present - @param num: provides the occurrence value - @returns a real name object - """ - names.o_bullet_object["container"] = screen_obj - names.o_bullet_object["occurrence"] = num + 1 - return names.o_bullet_object - -def get_text_object(screen_obj, txt): - """ - To obtain a text object based on text provided - @param screen_obj: provides the container on which the txt must be present - @returns a real name object - """ - names.o_text_object["container"] = screen_obj - names.o_text_object["text"] = txt - return names.o_text_object - -def set_property_text(text,obj): - """ Method to set object property based on text @param text : (string) treatment parameter text """ @@ -113,7 +92,7 @@ if type_combo_box is not None: squish.mouseClick(squish.waitForObjectExists(object)) - type_option = get_object_from_names(set_property_text(obj = names.o_option_combo_box,text = type[whichTypeIndex]),error_message=f"Option {type[whichTypeIndex]} object is missing",timeout_ms=5000) + type_option = get_object_from_names(set_Object_Text(obj = names.o_option_combo_box,text = type[whichTypeIndex]),error_message=f"Option {type[whichTypeIndex]} object is missing",timeout_ms=5000) if type_option is not None: squish.mouseClick(type_option) return True @@ -152,20 +131,7 @@ waitFor(lambda: not object.exists(slider_obj), 1000) except LookupError as e: test.fail(f"{parameter}: LookupError - {e}") - -def click_left_until_off(object_name): - parent_obj = waitForObject(object_name) - left_arrow = findObjectById(parent_obj, "_leftArrow") - - # Loop until the value becomes "off" - while findObject(object_name).value != 0.0: - squish.mouseClick(waitForObject(left_arrow)) - utils.waitForGUI(0.2) # Small delay to allow UI to update - -def get_title_text_obj(text): - names.o_title_Text["text"] = text - return names.o_title_Text - + def get_current_date_and_time(date_format='%Y/%b/%d - %H:%M'): date = datetime.now() return str(date.strftime(date_format)) \ No newline at end of file