However, Apple make this very difficult to do. It's possible, but it requires a hack and is not officially supported, the biggest problem being the running of unit tests which cannot be done consistently and headlessly, which pretty much negating the reason for having CI.
Where I'm working just now does indeed use CI (Jenkins with MacMini build slaves). It's an impressive set up, but is problematic.
At my suggestion, my colleague created a bug to try and encourage Apple to address this, but now we need your support. If you understand this pain and want Apple to address it (and can open an bug with Apple) please log a bug and use the following information:
Title: Support Running of Unit Tests Headlessly
Description: Duplicate of 12214314
Apple tools should better support Continuous Integration systems e.g Jenkins.
Of Particular concern is that the xcodebuild command does not take a test argument so we need to manually edit the emulator scripts to run tests headlessly (as stated in blogs like http://www.raingrove.com/2012/03/28/running-ocunit-and-specta-tests-from-command-line.html).
We shouldn't need to do this. We should be able to run tests from the commandline with the same ease that we press command-U to run them when the project is open.
Let's get Apple to really support iOS development in the enterprise! Thanks in advance.