How to edit/insert a new step for a MobileWeb(NOT native app, just a desktop web site running on mobile browser) site testing

We have a web site to test using Selenium both on Desktop and mobile browser. I could able to record and run the web based test just fine.

But due to form factor of the (Android)mobile browser, some menus are clubbed in as a hamburger icon. How to incorporate actions(click, waitToBeClickable etc) for this icon ?

I tried mobile spy using Android device, which is recognizing the mobile device and showing it in the Vysor just fine, but expecting an application apk bundle or application ID to open it in the preview. Since our AUT is a web site, I can’t figure out how to open it in the mobile browser.

I referred to this web documentation, but still could not figured out how to record an action on a web element in the mobile browser or write a locator for it.
If one has an idea, please refer me to that documentation or give me a suggestion.

1 Like

Hi there,

Thank you very much for your topic. Please note that it may take a little while before a member of our community or from Katalon team responds to you.

Thanks!

Hi,

Welcome to our community. I think you have reached to the correct document. Can you interact with your element like this: WebUI.click(findTestObject('Browser Application/button_Make Appointment')). You can create the test case testing Web UI on Katalon Studio then run with Mobile Browser

@Elly_Tran
Thanks for your reply.
I am doing exactly that. I record the steps on the desktop browser(then F12 and choosing mobile emulator mode, then browser shows the chosen mobile device GUI). Interestingly, a menu item when clicked shows a list of options(too many like >900, and a input box to filter when you type some thing in to it. I could able to click the menu, type a filter string, get a single filtered option, but the script could not ‘click’ on the thus filtered option. Prior to clicking, I checked for waitForElementPresent, ElementClickable , focus, mouseover, but still no use. I am getting this error message in the console.

WebUI.waitForElementPresent(‘Object Repository/TBD/Page_Home Z-Commerce/a_UNITED PIPE STEEL CORP(0010000219)’, 2)

Test Cases/MobileTests/TBD FAILED.

Reason:

groovy.lang.MissingMethodException: No signature of method: static com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords.waitForElementPresent() is applicable for argument types: (String, Integer) values: [Object Repository/TBD/Page_Home Z-Commerce/a_UNITED PIPE STEEL CORP(0010000219), ...]

Possible solutions: waitForElementPresent(com.kms.katalon.core.testobject.TestObject, int), waitForElementPresent(com.kms.katalon.core.testobject.TestObject, int, com.kms.katalon.core.model.FailureHandling), waitForElementNotPresent(com.kms.katalon.core.testobject.TestObject, int), waitForElementNotPresent(com.kms.katalon.core.testobject.TestObject, int, com.kms.katalon.core.model.FailureHandling)

at TBD.run(TBD:48)

How can I troubleshoot and/or overcome this issue ??

BTW, is there a WebUI method for outputting a String to the console window, like System.out.println(“String”) like in Java ? Just to check what the method calls return.

Hi,

Please make sure you input correctly the parameters in waitForElementPresent(), try to use findTestObject. To print out the log to the console, you can use KeywordUtil.logInfo() or println() function.

You can also use:
WebUI.comment("Your Text Here")