-
-
Notifications
You must be signed in to change notification settings - Fork 769
Closed
Labels
Description
Description
-
Please note this issue is for scroll action and not swipe, do please don't mark as duplicate of iOS Swipe action based on co-ordinates does swipe outside of co-ordinates provided #784
-
I want to do scroll action based on co-ordinates range as below
swipeObject.put("direction", "down");
swipeObject.put("startX", "90");
swipeObject.put("startY", "400");
swipeObject.put("endX", "90");
swipeObject.put("endY", "350");
swipeObject.put("duration", "2000");
js.executeScript("mobile: scroll", swipeObject);
Expected Result:
- Scroll action within given range of co-ordinates
Actual Result:
- Scroll action takes place 2 times
- Scroll action happens outside given range
Appium Server logs:
[debug] [MJSONWP] Responding to client with driver.getSession() result: {"udid":"2DC94AFA-BA4D-4BA6-A857-567C31B1BFC0","app":"/Users/vikramanna/Documents/vikram/AppiumSerenityPOC/tw_mobile.app","automationName":"XCUITest","deviceName":"iPhone SE","platformName":"iOS","platformVersion":"11.2","device":"iphone","browserName":"TWM Dev","sdkVersion":"11.2","CFBundleIdentifier":"com.totalwine.app.beta.dev"}
[HTTP] <-- GET /wd/hub/session/55349e11-f263-47b9-a260-afd9a1b68a67 200 62 ms - 405
[HTTP] --> POST /wd/hub/session/55349e11-f263-47b9-a260-afd9a1b68a67/execute {"script":"mobile: scroll","args":[{"duration":"2000","endY":"350","endX":"90","startY":"400","startX":"90","direction":"down"}]}
[debug] [MJSONWP] Calling AppiumDriver.execute() with args: ["mobile: scroll",[{"duration":"2000","endY":"350","endX":"90","startY":"400","startX":"90","direction":"down"}],"55349e11-f263-47b9-a260-afd9a1b68a67"]
[debug] [XCUITest] Executing command 'execute'
[debug] [BaseDriver] Waiting up to 18000 ms for condition
[debug] [JSONWP Proxy] Proxying [POST /element] to [POST http://localhost:8100/session/16D938C7-B971-4872-8F3A-E64DEA6EA39F/element] with body: {"using":"class name","value":"XCUIElementTypeApplication"}
[debug] [JSONWP Proxy] Got response with status 200: {"value":{"ELEMENT":"C513D936-4D05-4F67-AD64-1730D98FB6B9"},"sessionId":"16D938C7-B971-4872-8F3A-E64DEA6EA39F","status":0}
[debug] [JSONWP Proxy] Proxying [POST /wda/element/C513D936-4D05-4F67-AD64-1730D98FB6B9/scroll] to [POST http://localhost:8100/session/16D938C7-B971-4872-8F3A-E64DEA6EA39F/wda/element/C513D936-4D05-4F67-AD64-1730D98FB6B9/scroll] with body: {"direction":"down"}
[debug] [JSONWP Proxy] Got response with status 200: {"value":{},"sessionId":"16D938C7-B971-4872-8F3A-E64DEA6EA39F","status":0}
[debug] [MJSONWP] Responding to client with driver.execute() result: {}
[HTTP] <-- POST /wd/hub/session/55349e11-f263-47b9-a260-afd9a1b68a67/execute 200 6117 ms - 74
[HTTP] --> GET /wd/hub/session/55349e11-f263-47b9-a260-afd9a1b68a67 {}
[debug] [MJSONWP] Calling AppiumDriver.getSession() with args: ["55349e11-f263-47b9-a260-afd9a1b68a67"]
[debug] [XCUITest] Executing command 'getSession'
[debug] [JSONWP Proxy] Proxying [GET /] to [GET http://localhost:8100/session/16D938C7-B971-4872-8F3A-E64DEA6EA39F] with no body
[debug] [JSONWP Proxy] Got response with status 200: "{\n \"value\" : {\n \"sessionId\" : \"16D938C7-B971-4872-8F3A-E64DEA6EA39F\",\n \"capabilities\" : {\n \"device\" : \"iphone\",\n \"browserName\" : \"TWM Dev\",\n \"sdkVersion\" : \"11.2\",\n \"CFBundleIdentifier\" : \"com.totalwine.app.beta.dev\"\n }\n },\n \"sessionId\" : \"16D938C7-B971-4872-8F3A-E64DEA6EA39F\",\n \"status\" : 0\n}"
[XCUITest] Merging WDA caps over Appium caps for session detail response
[debug] [MJSONWP] Responding to client with driver.getSession() result: {"udid":"2DC94AFA-BA4D-4BA6-A857-567C31B1BFC0","app":"/Users/vikramanna/Documents/vikram/AppiumSerenityPOC/tw_mobile.app","automationName":"XCUITest","deviceName":"iPhone SE","platformName":"iOS","platformVersion":"11.2","device":"iphone","browserName":"TWM Dev","sdkVersion":"11.2","CFBundleIdentifier":"com.totalwine.app.beta.dev"}
[HTTP] <-- GET /wd/hub/session/55349e11-f263-47b9-a260-afd9a1b68a67 200 70 ms - 405
[HTTP] --> GET /wd/hub/session/55349e11-f263-47b9-a260-afd9a1b68a67 {}
Environment
- java client build version or git revision if you use some shapshot: 5.0.4
- Appium server version or git revision if you use some shapshot: v1.7.2-beta2
- Desktop OS/version used to run Appium if necessary: Mac
- Node.js version (unless using Appium.app|exe) or Appium CLI or Appium.app|exe: CLI
- Mobile platform/version under test: iOS Simulator 11.2
- Real device or emulator/simulator: Simulator
Details
Please provide more details, if necessary.
Code To Reproduce Issue [ Good To Have ]
Already mentioned in description
Ecxeption stacktraces
NA
Link to Appium logs
Already mentioned in description