![]() ![]() I run some tests using a Ubunto regular environment (no wayland) and the value of the Navigator.maxTouchPoints is ok (=10) This behavior remains the same after testing it with different Babylon versions and Chromium versions as well. Then I realized that the Navigator.maxTouchPoints = 0, even when the touch screen is connected. Looking into the browser’s console I can see an error reporting that the maxTouchPoints has been exceeded. The application runs well but some multitouch actions do not work. I have 2 different Linux setups both wayland based. MultiTouch.add(action1).add(action2).add(action3).add(action4).I’m working on migrating an application that uses Babylon on a windows environment to a Linux one. 'Multi Touch Object to add Multiple touch actions as per you need' 'Press Fourth action with x y coordinates wait 5 Seconds then release'Īction4.press(PointOption.point(X4, Y4)).waitAction(WaitOptions.waitOptions(Duration.ofMillis(5000))).release() 'Press Third action with x y coordinates wait 5 Seconds then release'Īction3.press(PointOption.point(X3, Y3)).waitAction(WaitOptions.waitOptions(Duration.ofMillis(5000))).release() 'Press Second action with x y coordinates wait 5 Seconds then release'Īction2.press(PointOption.point(X2, Y2)).waitAction(WaitOptions.waitOptions(Duration.ofMillis(5000))).release() 'Press First action with x y coordinates wait 5 Seconds then release'Īction1.press(PointOption.point(X1, Y1)).waitAction(WaitOptions.waitOptions(Duration.ofMillis(5000))).release() TouchAction action4 = new TouchAction(driver) 'Create Fourth action Object to "TouchAction" class' TouchAction action3 = new TouchAction(driver) 'Create Third action Object to "TouchAction" class' TouchAction action2 = new TouchAction(driver) 'Create Second action Object to "TouchAction" class' TouchAction action1 = new TouchAction(driver) 'Create First action Object to "TouchAction" class' MultiTouchAction multiTouch = new MultiTouchAction(driver) 'Create object to "MultiTouchAction" class ' 'Get Y4 coordinate of touchpoint 4 (Bottom Right Side)' 'Get X4 coordinate of touchpoint 4 (Bottom Right Side)' 'Get Y3 coordinate of touchpoint 3 (Bottom Left Side)' 'Get X3 coordinate of touchpoint 3 (Bottom Left Side)' 'Get Y2 coordinate of touchpoint 2 (Top Right Side)' 'Get X2 coordinate of touchpoint 2 (Top Right Side)' 'Get Y1 coordinate of touch action 1 (Top Left Side)' 'Get X1 coordinate of touchpoint 1 (Top Left Side)' 'Get Device Width and store to "device_Width" variable' 'Get Device Height and store to "device_Height" variable' 'Initializing Katalon Mobile Driver to Appium Driver'ĪppiumDriver driver = MobileDriverFactory.getDriver() Mobile.verifyElementVisible(findTestObject('MultiTouchTester/text_Touch Me'), 30) Mobile.waitForElementPresent(findTestObject('MultiTouchTester/text_Touch Me'), 30) 'Path of the Apk File Store in path variable'ĭef path = RunConfiguration.getProjectDir() + '/Data Files/MultiTouchTester.apk' ![]() Import io.appium.java_client.TouchAction as TouchAction Import io.appium.java_client.MultiTouchAction as MultiTouchAction Import io.appium.java_client.AppiumDriver as AppiumDriver Import .configuration.RunConfiguration as RunConfiguration Thus, we suggest the users utilize this feature where one can quickly automate the test scenario and easily manage test scripts. The final step is to add a method call statement and generate a multi-touch action chain.Īs you can see from the step-by-step guide above, there are repeated steps that would be easier to create in Script Mode.Add a method call statement and press first action with X, Y coordinates and wait for 5 seconds then release.Set all four touch actions on given X, Y Coordinates of the screen.Create an object of MultiTouchAction class.Repeat step 6 for touch action 2 ( top right side), touch action 3 ( bottom left side), and touch action 4 ( bottom right side).Add binary statement and get X, Y Coordinates for touch action 1 ( top left side).Then store it in a variable ' device_Width'. Call the ' Get Device Width' method and capture the width.Then store it in a variable ' device_Height'. Call the ' Get Device Height' method and capture the height.Initialize Katalon Mobile Driver to Appium Driver.In the displayed dialogue, in appFile, select Value Type as Variable and in Value passing the variable name as path.Select Start Application from mobile keyword and click on Input.We will use the MultiTouch Tester app to demonstrate automation testing on this typical behavior. This tutorial shows you how to perform a multi-touch action at four different points simultaneously. Multi-touch action often appears in gaming applications. How to Perform Multi-touch Actions in Mobile App in Katalon Studio ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |