ios driver with ruby

215 views
Skip to first unread message

Dan Franko

unread,
Jun 14, 2013, 3:48:10 PM6/14/13
to seleniu...@googlegroups.com
Anyone know what the syntax should be to start a native app with ruby or watir-webdriver is?  I've got no problems starting safari in a simulator, but I want to run a native app in either the simulator or a real device.

Here's the instructions for java. Is it only supported with java now/
http://freynaud.github.io/ios-driver/native.html

Thanks!

Luke Inman-Semerau

unread,
Jun 17, 2013, 2:06:40 PM6/17/13
to seleniu...@googlegroups.com
First off, François' repository should be considered dead, please look at the 'official' git repo for ios-driver:
http://ios-driver.github.io/ios-driver/native.html

As for using Ruby bindings to connect to a native app on device or simulator, take a look at the desired capabilities you should pass:
https://github.com/lukeis/seconf/blob/master/src/main/java/me/lukeis/example/drivers/iOSDriver.java#L11

Ruby can do equivalent to this example java code (in fewer lines...) :)

-Luke

Dan Franko

unread,
Jun 17, 2013, 2:33:08 PM6/17/13
to seleniu...@googlegroups.com
Great!  Thanks!  I think I just didn't realize I was on the dead one since they look so similar :).

jeevan

unread,
Jun 17, 2013, 6:26:04 PM6/17/13
to seleniu...@googlegroups.com
Hi All,

I tried to test with ios-driver . I'm getting the following error.

/Users/X/Library/Developer/Xcode/DerivedData/InternationalMountains-grnxatbfagbvuwadvmtrfnvxultb/Build/Products/Debug-iphonesimulator/InternationalMountains.app' but no main parameter was defined

                at com.beust.jcommander.JCommander.getMainParameter(JCommander.java:881)

                at com.beust.jcommander.JCommander.parseValues(JCommander.java:735)

                at com.beust.jcommander.JCommander.parse(JCommander.java:275)

                at com.beust.jcommander.JCommander.parse(JCommander.java:258)

                at com.beust.jcommander.JCommander.<init>(JCommander.java:203)

                at org.uiautomation.ios.server.IOSServer.init(IOSServer.java:87)

                at org.uiautomation.ios.server.IOSServer.<init>(IOSServer.java:61)

                at org.uiautomation.ios.server.IOSServer.main(IOSServer.java:65) 


Was able to build the app successfully and even it opens up the iPhone Simulator.

Appreciate your help on this.

Thanks,
Jeevan

--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to selenium-user...@googlegroups.com.
To post to this group, send email to seleniu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/eae98e56-7a28-4c7f-ad01-6a6bd85bce9a%40googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.
 
 

Rohit Kadam

unread,
Jun 26, 2013, 3:21:31 AM6/26/13
to seleniu...@googlegroups.com
Hi Luke,

How can I open any site on simulator through ruby code.
I have started ios-driver server.
Trying to run :-

require 'selenium-webdriver'
driver = Selenium::WebDriver.for :remote, :url => "http://localhost:5555/wd/hub", :desired_capabilities => :iphone

gives me an error:-

NoMethodError: undefined method `downcase' for nil:NilClass

Dan Franko

unread,
Jun 26, 2013, 8:49:43 AM6/26/13
to seleniu...@googlegroups.com
What's your selenium-webdriver version?

Rodrigo Martin

unread,
Apr 15, 2014, 2:06:30 PM4/15/14
to seleniu...@googlegroups.com
I'm also trying to start a page in iphone/ipad simulator, which caps should be passed, using ruby bindings? Thanks a lot!
Reply all
Reply to author
Forward
0 new messages