Katalon can not find text field for input

Hi!

Colleagues, help, please. It’s my first time in autotests.

I recorded the test script - everything is fine.

I run test, it goes to the place where I need to click on the field for open text-set field. And test stopped with mistake.

What I did wrong?


1.

2.

3.

1.png

2.png

3.png

script.txt

log.txt

4.png

Maybe you need to add ‘Wait For Element Visible’ keyword before that step. The error message is: ‘Element is not visible’, so I think you should add that keyword.

Ana Hong said:

Maybe you need to add ‘Wait For Element Visible’ keyword before that step. The error message is: ‘Element is not visible’, so I think you should add that keyword.

Done.

But, now I see next problem:

Found 27 web elements with id: ‘Object Repository/Page_ (1)/Page_/input_ui-autocomplete-input’ located by ‘By.xpath: //input[count(. | //[@type = ‘text’]) = count(//[@type = ‘text’])]’ in ‘30’ second(s)

Unable to set text ‘тест’ of object ‘Object Repository/Page_ (3)/input_ui-autocomplete-input’ (Root cause: org.openqa.selenium.InvalidElementStateException: invalid element state: Element is not currently interactable and may not be manipulated

Maybe, it’s a wrong locator…

Add this line to the script, just before the element that shows the error.

WebUI.delay(3)

I often use scroll to element and then a delay if needed

Perhaps check your object is being identified uniquely. It shows 27 Elements are found.