automate device settings

1,011 views
Skip to first unread message

Dan Dover

unread,
Mar 6, 2013, 8:09:26 PM3/6/13
to appium-...@googlegroups.com
Has anyone heard of / seen a way to automate the settings application on the actual iOS device?  Not the simulator so no AppleScript, no sikuli...  Need to tweak the VPN settings and verify a profile is installed.

David Luu

unread,
Mar 7, 2013, 6:24:23 PM3/7/13
to appium-...@googlegroups.com
Depends if you're willing to pay for the functionality (until there are free / open source equivalents).

From what I've heard, experitest.com has tools to control actual devices (not just with simulator). You just attach to computer via USB, etc. and connect via the tool to drive it. Though for iOS you do or did have to jailbreak it, not sure if that's still required anymore. But the tool might not be free, as it originally wasn't. It is similar to Sikuli in concept but that it could drive actual devices and not just simulator.

Dan Dover

unread,
Mar 7, 2013, 6:37:10 PM3/7/13
to appium-...@googlegroups.com
Thanks David.  It looks like http://experitest.com is similar to https://www.testplant.com/products/eggplant/mobile/...I was hoping for something that didn't require a jailbreak and wasn't OCR/image capture, but I guess beggars can't be choosers.  I'm hoping someone knows of another way, but chances are slim on iOS.

David Luu

unread,
Mar 7, 2013, 8:08:57 PM3/7/13
to appium-...@googlegroups.com
Now that you mention it, Appium only works within simulator? Or can it work to drive the device (if you jailbreak it)?

You can also check on https://github.com/freynaud/ios-driver to see if that does what you need (I'm not sure)

Jonathan Lipps

unread,
Mar 7, 2013, 9:05:39 PM3/7/13
to David Luu, appium-...@googlegroups.com
Appium also works on real devices, without jailbreaking. It might be able to automate the settings app. I think we can launch it the same way we launch mobile safari! Not sure about on real devices with that technique, though…

--
http://appium.io
---
You received this message because you are subscribed to the Google Groups "Appium-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to appium-discus...@googlegroups.com.
Visit this group at http://groups.google.com/group/appium-discuss?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Dan Dover

unread,
Mar 8, 2013, 2:51:39 PM3/8/13
to appium-...@googlegroups.com, David Luu
Jonathan, tell us more about how you're launching mobile safari or point out that code.... I'd love to automate some settings. 

David, appium works great on devices.

Jonathan Lipps

unread,
Mar 8, 2013, 3:53:55 PM3/8/13
to Dan Dover, appium-...@googlegroups.com, David Luu
OK, I added an example of automating Preferences.app to turn off Auto-Correction:


If you follow the code you'll see how we find the app on the system and launch Appium with it.

A wrinkle is that builtin apps by default launch in the iPad Simulator, and I wrote this test for the iPhone version. Later today I should hopefully be able to respect the 'device' desired capability to launch in iphone or ipad on request. Meanwhile, you can edit the Info.plist file of the apps in question to make it run on only iphone or ipad (by removing '1' or '2' from UIDeviceFamily).

Cheers,
Jonathan

vamsi krishna racha

unread,
Jun 10, 2013, 11:44:10 PM6/10/13
to appium-...@googlegroups.com, Dan Dover, David Luu
Hi Jonathan,

I tried appium GUI to connect to the real ios device, input the device udid and bundleID as com.apple.Preferences for opening the preferences app for automation. when i launch and click on "i" button which through me an error, below is the error from the GUI. Please help me resolving this issue. THanks in Advance.

info: Welcome to Appium v0.7.1 (REV 055dcdf7ef1915a0a15a4bc9daed1c748c98f2fa)


info: Appium REST http interface listener started on 0.0.0.0:4723

info: socket.io started


info: Responding to client with success: {"status":0,"value":{"build":{"version":"0.7.1","revision":"055dcdf7ef1915a0a15a4bc9daed1c748c98f2fa"}}}


debug: Appium request initiated at /wd/hub/status


GET /wd/hub/status 200 56ms - 143

info: Responding to client with success: {"status":0,"value":[]}

GET /wd/hub/sessions 200 1ms - 32

info: App is an iOS bundle, will attempt to run as pre-existing

info: Creating new appium session a33f7332-5830-42ad-9142-0486f8cf03eb

info: Cleaned up instruments socket /tmp/instruments_sock

info: Not setting device type since we're connected to a device

info: instruments is: /Applications/Xcode.app/Contents/Developer/usr/bin/instruments

info: [INSTSERVER] Instruments socket server started at /tmp/instruments_sock

info: Attempting to run app on real device with UDID 6a3b2345721f57bf4350eaf87efbb454cc1452dc

info: Spawning instruments with command: /Applications/Xcode.app/Contents/Developer/usr/bin/instruments -t /Applications/Appium.app/Contents/Resources/node_modules/appium/app/uiauto/Automation.tracetemplate -w 6a3b2345721f57bf4350eaf87efbb454cc1452dc com.apple.Preferences -e UIASCRIPT /Applications/Appium.app/Contents/Resources/node_modules/appium/app/uiauto/bootstrap.js -e UIARESULTSPATH /tmp/fc71788c-098d-43b8-9d4b-7db582cf9db5

info: And extra without-delay env: {}

info: [INST STDERR] 2013-06-10 20:43:11.404 instruments[8939:2407] Error fetching kdebug events

2013-06-10 20:43:11.404 instruments[8939:707] Connection to the remote device lost while launching target. Aborting...


info: [INST STDERR] 2013-06-10 20:43:11.417 instruments[8939:707] Recording cancelled : At least one target failed to launch; aborting run

Instruments Trace Error : Failed to start trace.


info: [INSTSERVER] Instruments exited with code 253

info: Responding to client with error: {"status":6,"value":{"message":"A session is either terminated or not started","origValue":"Instruments did not launch successfully--please check your app paths or bundle IDs and try again"},"sessionId":"a33f7332-5830-42ad-9142-0486f8cf03eb"}

POST /wd/hub/session 500 4505ms - 270

info: Clearing out appium devices


debug: Appium request initiated at /wd/hub/sessions

debug: Appium request initiated at /wd/hub/session

debug: Request received with params: {"desiredCapabilities":{}}

debug: No device id or app, not installing to real device.

debug: Creating instruments

error: Instruments did not launch successfully, failing session

error: Failed to start an Appium session, err was: Instruments did not launch successfully--please check your app paths or bundle IDs and try again

Dan Dover

unread,
Jun 11, 2013, 8:41:47 PM6/11/13
to appium-...@googlegroups.com
Pretty great idea.  I haven't tried it yet but I suppose it could work on a real device too?  I'd need to jailbreak to get the arm binary and resign it with my developer profile...otherwise I can't think of a reason it wouldn't work.


On Wednesday, March 6, 2013 5:09:26 PM UTC-8, Dan Dover wrote:

vamsi krishna racha

unread,
Jun 11, 2013, 8:48:13 PM6/11/13
to Dan Dover, appium-...@googlegroups.com
can you please explain me in details about this "get the arm binary and resign it with my developer profile", and let me know How you would do it.


You received this message because you are subscribed to a topic in the Google Groups "Appium-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/appium-discuss/HR8yDkojZ3U/unsubscribe?hl=en.
To unsubscribe from this group and all its topics, send an email to appium-discus...@googlegroups.com.

Dan Dover

unread,
Jun 11, 2013, 8:55:28 PM6/11/13
to vamsi krishna racha, appium-...@googlegroups.com
Haha sure.  Which part, copying the arm binary off the device or resigning?

You received this message because you are subscribed to the Google Groups "Appium-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to appium-discus...@googlegroups.com.

Vamsikrishna Racha

unread,
Jun 11, 2013, 9:15:28 PM6/11/13
to Dan Dover, appium-...@googlegroups.com
Both please.....haha

vamsi krishna racha

unread,
Jul 16, 2013, 3:22:28 PM7/16/13
to appium-...@googlegroups.com
Dan,
Where you able to try it to automate the preferences app on a real device?

Ipsita Samantarai

unread,
Aug 15, 2013, 11:21:58 AM8/15/13
to appium-...@googlegroups.com, Dan Dover, David Luu
Hello Guys,

Any clue on how to remove the error mentioned by ", vamsi krishna ". I am also getting the same error while running my webapp on device through appium. I installed webkit proxy as well. Please let me know if i have missed something.

Appreciate your help.
Reply all
Reply to author
Forward
0 new messages