I recorded a session with one of our web applications, using Chrome. During playback, a failure was encountered while attempting to populate a text box. Screen shots of the Katalon session and the web page it was manipulating are attached.
We commonly link radio buttons to a text box used to enter database search criteria, allowing the user to specify whether to search for values that either Starts With or Contains the entered value. As you can see from the webpage screen shot, the Supplier Number radio button is set to Starts With, but the Katalon playback session is mistakenly using the object input_Contains_supplier_number_search_text_id when the set text operation fails.
This appears to me to be a bug. Please advise.
Application webpage image during “set text” failure:
I believe your guess is incorrect. The radio button was not altered during the recorded session. “Starts With” is the default. “Contains” is the object Katalon was inexplicably using.
Do you want the HTML from the page immediately before or immediately after the failure? (It’s late here now; I will provide that tomorrow.)
Not sure what you mean by “definition for your Test Objects”. Is the Katalon screen shot insufficient?
@russ_thomas means, that you should provide information - how the related html object - which is stored in the section “object repository” is defined.
I believe that’s correct, Russ. Here’s the script view of the recorded session, with the line in question highlighted. Note that the variable is input_Contains_supplier_number_search_text_id, when I would have been expected input_Starts_With_supplier_number_search_text_id.
Thanks for your input @masdesign. Katalon is totally new to me. I’m familiarizing myself with it for evaluation purposes. I have minimal Katalon domain knowledge.
There are no related objects in “Object Repository”. I am simply replaying the activity I recorded, and captured as a “Test Case”.
Well that is concerning. If you recorded a session, the recording tool should have built Test Objects in the Object Repository. And if it didn’t and you didn’t write the script by hand, how did Katalon produce it?
It’s the definition of each Test Object that interests me. If you recorded them, they are likely to be using xpaths and/or css to locate the HTML elements on the page when the test is executing.
What we’re trying to establish is: Did the recorder screw up? Did it create bad xpaths? If so, how come this failed for you (IOW, how come we’re not inundated with users complaining it’s badly broken)?
So that’s where we are. Post a screenshot of the OR showing the definitions for the element it SHOULD be using and the element it’s ACTUALLY using. The Test Object IDs are the references you can see in your highlighted line in your previous screenshot. Essentially, the content of findTestObject(…)
Being pragmatic for a moment: we could just edit the script in Script View and move on with our lives… but then we don’t learn anything
In Object Repository folder on the left side, navigate into the subdirectory as you see it in the findObject statement you highlighed blue. then double-click the object input-contains-supplier-number-search-id)
After that, provide a screenshot of what is displayed in your Katalon.