Home > jenkins, potd > POTD: iOS device detection in Jenkins

POTD: iOS device detection in Jenkins

October 5th, 2012

I was talking to my colleague Mark Prichard about mobile development with Jenkins, and I came up with this idea.

If you are doing iOS app testing with real devices, you need to tether the device with a computer so that you can push the app-to-be-tested to the device. In a local development environment, you’d naturally do this by hooking up a device to your laptop.

But in the CI environment, we can do better. Imagine if you have a Jenkins master connected to a dozen Mac minis, where each Mac mini is then connected to various iOS devices. There’s nothing stopping Jenkins from listing up all the devices connected to all the slaves. Then based on this information, Jenkins can lease devices to builds.

Say someone wants to run a test somewhere. Jenkins can find an unused device and push it, then inject the coordinate of that device to the build. Or how about the axis in a matrix project that allows you to say “I need this test to run with iPhone 3GS,4,5 and iPad 2,3″ then Jenkins will run 5 runs of the tests in parallel?

To that end, as a post-JavaOne fun project, I developed a plugin that lists up all the iOS devices connected to Jenkins.

And just to show that we can list up various properties of this device:

I should be able to combine this with something like fruitstrap so that you can deploy apps from anywhere to any device connected to your Jenkins build farm.

What do you think? Shouldn’t this be interesting? Any thoughts?

jenkins, potd , ,

  1. huoen
    October 9th, 2012 at 10:15 | #1

    Hi,Thanks for your share idea and code progect ,i’v install from jenkins plugin-market.
    How to list other Mac-iOSdevices ??

  2. October 10th, 2012 at 12:04 | #2

    Not sure if I understand. What do you mean by “other iOS devices”? It should list them all.

  3. Ankush
    July 24th, 2013 at 08:20 | #3

    is any way to get all connected devices UID in single variable ?

  4. Ankush
    July 24th, 2013 at 08:23 | #4

    Hi Thanks for the information. Please let me know, How can I get all devices UIDs in single variable ?

  1. No trackbacks yet.