Unable to move mouse over object running tests on Mac from Terminal

Unable to move mouse over object running tests on Mac from Terminal. Getting error like:

2019-03-12 19:19:58.209 ERROR c.k.katalon.core.main.TestCaseExecutor - :x: Test Cases/PrometheanTV/Overlays Creation and Properties verification/1-FieldEntryFormOverlayCreationOnTwitchChannelAndPropertiesVerification FAILED.
Reason:
com.kms.katalon.core.exception.StepFailedException: Unable to move mouse over object ‘Object Repository/Channels/FirstChannelTile’
at com.kms.katalon.core.keyword.internal.KeywordMain.stepFailed(KeywordMain.groovy:48)
at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.stepFailed(WebUIKeywordMain.groovy:65)
at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.runKeyword(WebUIKeywordMain.groovy:27)
at com.kms.katalon.core.webui.keyword.builtin.MouseOverKeyword.mouseOver(MouseOverKeyword.groovy:90)
at com.kms.katalon.core.webui.keyword.builtin.MouseOverKeyword.execute(MouseOverKeyword.groovy:67)
at com.kms.katalon.core.keyword.internal.KeywordExecutor.executeKeywordForPlatform(KeywordExecutor.groovy:56)
at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords.mouseOver(WebUiBuiltInKeywords.groovy:776)
at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords$mouseOver$8.call(Unknown Source)
at 1-FieldEntryFormOverlayCreationOnTwitchChannelAndPropertiesVerification.run(1-FieldEntryFormOverlayCreationOnTwitchChannelAndPropertiesVerification:45)
at com.kms.katalon.core.main.ScriptEngine.run(ScriptEngine.java:194)
at com.kms.katalon.core.main.ScriptEngine.runScriptAsRawText(ScriptEngine.java:119)
at com.kms.katalon.core.main.TestCaseExecutor.runScript(TestCaseExecutor.java:331)
at com.kms.katalon.core.main.TestCaseExecutor.doExecute(TestCaseExecutor.java:322)
at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(TestCaseExecutor.java:301)
at com.kms.katalon.core.main.TestCaseExecutor.accessMainPhase(TestCaseExecutor.java:293)
at com.kms.katalon.core.main.TestCaseExecutor.execute(TestCaseExecutor.java:227)
at com.kms.katalon.core.main.TestSuiteExecutor.accessTestCaseMainPhase(TestSuiteExecutor.java:129)
at com.kms.katalon.core.main.TestSuiteExecutor.accessTestSuiteMainPhase(TestSuiteExecutor.java:112)
at com.kms.katalon.core.main.TestSuiteExecutor.execute(TestSuiteExecutor.java:81)
at com.kms.katalon.core.main.TestCaseMain.startTestSuite(TestCaseMain.java:157)
at com.kms.katalon.core.main.TestCaseMain$startTestSuite$0.call(Unknown Source)
at TempTestSuite1552411149875.run(TempTestSuite1552411149875.groovy:35)

Please, assist how to solve the issue. Thanks.

If you run the test cases in KS does it run and pass fine? Try adding some delays before the step in question to troubleshoot - it may be that the object has not loaded yet and therefore the mouse cannot locate it causing this error.

No, test fails on mouse hover step. Tried to launch with delays, but it not works.

If it is failing in KS aswell then there is something not set up properly with your script - could you send me through your script steps

‘Open Browser’
WebUI.openBrowser(GlobalVariable.URL)

‘Maximize Window’
WebUI.maximizeWindow()

‘Navigate to Sign In page’
WebUI.navigateToUrl(GlobalVariable.SignIn)

‘Enter user email’
WebUI.setText(findTestObject(‘Object Repository/input_Email Address_usernameOr’), comdev_usn)

‘Enter user password’
WebUI.setText(findTestObject(‘Object Repository/input_Forgot Password_password’), comdev_pwd)

‘Click Sign In button’
WebUI.click(findTestObject(‘Object Repository/button_Sign In’))

‘Verify you are on Channels page’
WebUI.verifyElementText(findTestObject(‘Channels Page’), ‘Channels’)

‘Wait for Twitch Channel Tile is visible’
WebUI.waitForElementVisible(findTestObject(‘Channels/FirstChannelTile’), 3)

‘Hover mouse on Twitch Channel’
WebUI.mouseOver(findTestObject(‘Channels/FirstChannelTile’))

‘Click Open button on Twitch Channel tile’
WebUI.click(findTestObject(‘Channels/div_Open_FirstChannel’))

‘Proceed to Live Streams tab’
WebUI.click(findTestObject(‘Object Repository/md-tab-item_Live Streams’))

‘Click Edit button on available Stream’
WebUI.click(findTestObject(‘button_Edit_FirstStream’))


Fails on ‘Hover mouse on Twitch Channel’ step.
It runs successfully on Windows (Web and Console), but fails on Mac Mini if I run it from console.

I think this issue could be related to configs or system path of Katalon Studio on Mac. Test Cases were created on Windows and transferred to Mac Mini.

Is it set to locate the element by xpath? Just thinking because you have transfered it over, yes its visible but the location on the page may have changed therefore the mouse cannot locate it. Maybe try playing around with the xpath/attributes to locate the element instead.

Transfering to mac shouldnt cause any issues - sometimes it can cause problems with the project files but youve been able to open the project fine and can run it so it should be fine theoretically.

Other than that - im not sure, maybe you should try re-recording the test and see if it works

Yes, I re-captured objects by xpath and css in Chrome on Mac, but it’s not helped.

Solved this issue by removing all external libraries in KS on Mac. Now it works fine in terminal mode. Thanks for help! :wink:

1 Like

Im glad you managed to resolve it :slight_smile: