Good afternoon! I need help. the task to select an element from the drop-down list. How to choose a specific item I figured out. Now the task: one test case is executed with different input data. Part of the input is a selection from the drop-down list. Can I change which element to access during the test or change the characteristic (xpath) of the element to select the desired item in the drop-down list?
Thank you in advance
new_btn = WebUI.modifyObjectProperty(findTestObject(‘Page/Element_1527231272674’), ‘xpath’, ‘equals’, ‘//span[(text() = \’+48\’)]’,
I tried this method. the new object is not located. what type of parameter should “equals” have? if I type in the section of the script it tinted blue. is it normal?
Your test object should already have xpath property, and it should be in the object repository. What I usually do is I have a general object with some xpath in the object repository, and I use that object when I need to use the WebUI.modifyObjectProperty().
How can I check that the xpath value has changed? now the value of xpath does not change
Are you sure it doesn’t change? What do you see in the logs?
05-25-2018 02:48:23 PM - [INFO] - Check Test Object
05-25-2018 02:48:23 PM - [INFO] - Check property name
05-25-2018 02:48:23 PM - [INFO] - Check modify value
05-25-2018 02:48:23 PM - [INFO] - Check match condition
05-25-2018 02:48:23 PM - [PASSED] - Modify property of object successfully
the next step is to click on the changed item (xpath at the element remained old)