Swipe and touch Action on Safari iOS

Hello,
I’m trying to make a swipe on Safari on Ipad iOS 8.1, with ruby.
Since “driver.execute_script ‘mobile: swipe’” is depreciate on Appium 1.3.5, I’m trying to use TouchAction, but I’m not able to do use them correctly.
I’m trying Appium::TouchAction.new.swipe( startX: 500, startY:300, endX: 600, endY: 300, duration: 3) and this is what I’ve got :
[4] pry(#)> Appium::TouchAction.new.swipe( startX: 500, startY:300, endX: 600, endY: 300, duration: 3)
=> #<Appium::TouchAction:0x007fdf935ba7a0
@actions=
[{:action=>:press, :options=>{:x=>0, :y=>0}}, {:action=>:wait, :options=>{:ms=>3}}, {:action=>:moveTo, :options=>{:x=>0, :y=>0}}, {:action=>:release}]>

If I had .perform at the end, I’ve got “not yet implemented”.
Same thing for tap :
[8] pry(#)> Appium::TouchAction.new.tap( x: 500, dy:300, duration: 3).perform
Selenium::WebDriver::Error::UnknownError: Not yet implemented. Please help us: http://appium.io/get-involved.html

I really don’t know how to use this ToucAction.
Are they ok for Safaro or Chrome Browser ?

My caps :
capabilities = {
caps: {
‘platformName’ => ‘iOS’,
‘platformVersion’ => ‘8.1’,
‘deviceName’ => ‘iPad Air’,
‘browserName’ => ‘Safari’
},
appium_lib: {
sauce_username: nil, # don’t run on Sauce
sauce_access_key: nil
}
}
@driver_appium = Appium::Driver.new(capabilities)
@driver = @driver_appium.start_driver
Appium.promote_appium_methods Object

I’m sure I’ve got just a little error, thanks for helping me !

To summarize my problem :
I want to swipe on Safari on simulator Xcode >5 but it looks like they are no way to do this since Apple change it.
But can we make a swipe on Chrome on real Android device ?
(I have to test this too)
Thanks a lot !

Ok I get it ! I have to switch context and go to NATIVE to swipe and Chrome.
So my last question is : is it possible to swipe on iOS Safari on simulator ?
Thanks !

Hi I haven’t been able to do that myself. in the 1.3.X.

I hav created an issue for this:

Even I have the same problem, seems we cannot do Appium touch action on web context ,

If anyone found any solution please share

You guys can use jQuery with the help of JavaScript executor to scroll on ios safari it works very well and I have found this after a alot of tries
But please make sure to use some method which waits for jquery to be inactive