hi, I am trying to use swipe the current page up and show next screen.
I am using this method snippets:
public void swipeWholePage(AndroidDriver driver, int during) {
//scroll from end of the page to the top of page so that on y-asis, from height to 0
int width = driver.manage().window().getSize().width;
int height = driver.manage().window().getSize().height;
driver.swipe(width / 2, height, width / 2, 0, during);
// wait for page loading
}
but waht I got is the log said :
info: [debug] Pushing command to appium work queue: [“getDeviceSize”]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“getDeviceSize”,“params”:{}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: getDeviceSize
info: [debug] [BOOTSTRAP] [debug] Returning result: {“value”:{“width”:1080,“height”:1776},“status”:0}
info: [debug] Responding to client with success: {“status”:0,“value”:{“width”:1080,“height”:1776},“sessionId”:“80f213a4-06df-4977-92ad-3b9aeeed2d88”}
info: ← GET /wd/hub/session/80f213a4-06df-4977-92ad-3b9aeeed2d88/window/current/size 200 8.025 ms - 100 {“status”:0,“value”:{“width”:1080,“height”:1776},“sessionId”:“80f213a4-06df-4977-92ad-3b9aeeed2d88”}
info: → GET /wd/hub/session/80f213a4-06df-4977-92ad-3b9aeeed2d88/window/current/size {}
info: [debug] Pushing command to appium work queue: [“getDeviceSize”]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“getDeviceSize”,“params”:{}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: getDeviceSize
info: [debug] [BOOTSTRAP] [debug] Returning result: {“value”:{“width”:1080,“height”:1776},“status”:0}
info: [debug] Responding to client with success: {“status”:0,“value”:{“width”:1080,“height”:1776},“sessionId”:“80f213a4-06df-4977-92ad-3b9aeeed2d88”}
info: ← GET /wd/hub/session/80f213a4-06df-4977-92ad-3b9aeeed2d88/window/current/size 200 6.973 ms - 100 {“status”:0,“value”:{“width”:1080,“height”:1776},“sessionId”:“80f213a4-06df-4977-92ad-3b9aeeed2d88”}
info: → POST /wd/hub/session/80f213a4-06df-4977-92ad-3b9aeeed2d88/touch/perform {“actions”:[{“action”:“press”,“options”:{“x”:540,“y”:1776}},{“action”:“wait”,“options”:{“ms”:5000}},{“action”:“moveTo”,“options”:{“x”:540,“y”:0}},{“action”:“release”,“options”:{}}]}
info: [debug] Pushing command to appium work queue: [“swipe”,{“startX”:540,“startY”:1776,“endX”:540,“endY”:0,“steps”:140}]
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“action”,“action”:“swipe”,“params”:{“startX”:540,“startY”:1776,“endX”:540,“endY”:0,“steps”:140}}
info: [debug] [BOOTSTRAP] [debug] Got command of type ACTION
info: [debug] [BOOTSTRAP] [debug] Got command action: swipe
info: [debug] [BOOTSTRAP] [debug] Display bounds: [0,0][1080,1776]
info: [debug] [BOOTSTRAP] [debug] Returning result: {“value”:“Coordinate [x=540.0, y=1776.0] is outside of element rect: [0,0][1080,1776]”,“status”:13}
info: [debug] Responding to client with error: {“status”:13,“value”:{“message”:“An unknown server-side error occurred while processing the command.”,“origValue”:“Coordinate [x=540.0, y=1776.0] is outside of element rect: [0,0][1080,1776]”},“sessionId”:“80f213a4-06df-4977-92ad-3b9aeeed2d88”}
info: ← POST /wd/hub/session/80f213a4-06df-4977-92ad-3b9aeeed2d88/touch/perform 500 11.338 ms - 244
info: → DELETE /wd/hub/session/80f213a4-06df-4977-92ad-3b9aeeed2d88 {}
info: Shutting down appium session
info: [debug] Pressing the HOME button
info: [debug] executing cmd: C:\Android\AndroidSDK\platform-tools\adb.exe -s 022SSE146M005259 shell “input keyevent 3”
info: [debug] Stopping logcat capture
info: [debug] Logcat terminated with code null, signal SIGTERM
info: [debug] [BOOTSTRAP] [debug] Got data from client: {“cmd”:“shutdown”}
info: [debug] [BOOTSTRAP] [debug] Got command of type SHUTDOWN
info: [debug] [BOOTSTRAP] [debug] Returning result: {“value”:“OK, shutting down”,“status”:0}
info: [debug] [BOOTSTRAP] [debug] Closed client connection
info: [debug] Sent shutdown command, waiting for UiAutomator to stop…
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: numtests=1
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: stream=.
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: id=UiAutomatorTestRunner
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: test=testRunServer
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: class=io.appium.android.bootstrap.Bootstrap
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: current=1
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS_CODE: 0
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS: stream=
info: [debug] [UIAUTOMATOR STDOUT] Test results for WatcherResultPrinter=.
info: [debug] [UIAUTOMATOR STDOUT] Time: 40.655
info: [debug] [UIAUTOMATOR STDOUT] OK (1 test)
info: [debug] [UIAUTOMATOR STDOUT] INSTRUMENTATION_STATUS_CODE: -1
info: [debug] UiAutomator shut down normally
info: [debug] Cleaning up android objects
info: [debug] Cleaning up appium session
info: [debug] Responding to client with success: {“status”:0,“value”:null,“sessionId”:“80f213a4-06df-4977-92ad-3b9aeeed2d88”}
info: ← DELETE /wd/hub/session/80f213a4-06df-4977-92ad-3b9aeeed2d88 200 824.161 ms - 76 {“status”:0,“value”:null,“sessionId”:“80f213a4-06df-4977-92ad-3b9aeeed2d88”}
could anyone help me to check what is wrong with my code snippest