paypal/SeLion

injecting javascript to exercise tap() doesn't work with Appium 1.5 and beyond

Closed this issue · 9 comments

Using javascript to exercise tap instead of using touchActions throws an error with versions of Appium 1.5 and beyond (1.5.2, 1.5.3).

Related to:
appium/appium#6132

mach6 commented

I recommend we fix this after the 1.1.0 release

mach6 commented

@brandontineo Are you still planning to submit a PR for this? Thanks!

@mach6 selion use scripts a lot for IOS, Is there any specific reason for that?

I am going to work on support appium 1.5.x by removing those scripts and replacing them with appium commands; Anything i should consider? Any suggestion?

mach6 commented

@alizelzele using js injection was more reliable at the time. Now, that the appium community is taking a different course, we must, in turn, adjust. It looks like the TouchActions api is now the preferred approach. If you want to pick up this PR, that would be awesome.

FYI - I had a preliminary conversation with @sebady about this issue. We agreed that any fix would be merged AFTER SeLion 1.1.0 is released.

Cheers!

@mach6 sorry I was busy I did not find time to update my codes. I was not able to simulate doubleTap for IOS only by TouchActions.
I tried:

  new TouchAction(this).tap(webElement).release().waitAction(100).tap(webElement).release().perform();

  new TouchAction(this).tap(webElement).perform();
  new TouchAction(this).tap(webElement).perform();

  new TouchAction(this).tap(webElement).perform().tap(webElement).perform();

None of these 3 does the job. Am I missing anything?

p.s: do we still need tap with options?

@mach6 created pull request for updating to appium 1.5 at #313 .

mach6 commented

@alizelzele Thanks for the PR. Should we also add support for MultiTouch (see https://github.com/appium/appium/blob/master/docs/en/writing-running-appium/touch-actions.md)?

@mach6 touch and multi touch are already supported in AppiumDriver By performTouchAction and performMultiTouchAction; although they seems to not be working in double click case.
If we want to support it in Selion way, it should be implemented in the tap with options, otherwise it is already in there.

fixed by #313