19. Requirement: OS X
• macminicolo.net
• hosted-ci.com
• cisimple.com
• macincloud.com
• hostmyapple.com
• macminivault.com
• xcloud.me
20. Requirement: OS X
• macminicolo.net
• hosted-ci.com
t ni ght,
• cisimple.com un a
to r ac,
dul e CI n M
• macincloud.com
Or sche your ow ep...
on u sle
e yo
• hostmyapple.com whil
• macminivault.com
• xcloud.me
23. Credentials
• The CI server needs access to your
repository
• SSH key
• The CI server needs Keychain credentials if
you want to sign your builds
• Developer certificate and profiles
24. Keychain
• Export and Import using Keychain Access app
• Keys and Certificates
• Or use the command line:
• sudo security import /path/to/distribution.cer -k /Library/Keychains/
System.keychain
• sudo security import /path/to/distribution.p12 -k /Library/Keychains/
System.keychain
• Don’t forget about provisioning profiles
• Troubleshooting: http://tinyurl.com/iOSDevToolTroubles
26. Avoid this error
from Xcode
RunPlatformUnitTests:
warning: Skipping tests;
the iPhoneSimulator platform does
not currently support application-
hosted tests (TEST_HOST set).
35. Prefer Scripts
over CI Plugins
• More flexibility
• More resilient to Apple’s changes
• More power to adapt and expand (specificity)
• Less coupling to the specific CI server type
• You can version control the settings easier
54. Ensure Return Codes
• If the tool you are invoking in your script
doesn’t return an exit code indicating
pass/fail, it’s up to you.
• Unix-friendly 0 (success) or 1 (failure)
56. Test against multiple
SDKs
-sdk iphonesimulator5.0
-sdk iphonesimulator5.1
-sdk iphonesimulator6.0
57.
58. Other Tools
to Know About
• xcode-select (manage xcode path)
• Overridden by DEVELOPER_DIR
• xcrun (find and run dev tools)
• ibtool (for Interface Builder files)
• /Applications/Xcode.app/Contents/Developer/usr/bin/
• Variables in Xcode
• “Build Settings Reference”
65. OCUnit2JUnit for
Test Results
• ocunit2junit.rb
• https://github.com/ciryon/OCUnit2JUnit
• Converts output to JUnit format for easier
transformation to HTML
69. UIAutomation
Alternatives
• Frank • Objective C Slim
(ocslim)
• (iCuke)
• AutomationKit
• KIF
• Sikuli
• Calabash
• MonkeyTalk (formerly
• UISpec FoneMonkey)
• Bromine • Plus other commercial
tools, such as Telerik Test
Studio for iOS
97. TestFlight Alternatives
• HockeyApp
• http://hockeyapp.net
• Also has a Jenkins plugin (forked)
• BetaBuilder for iOS
• http://www.hanchorllc.com/betabuilder-for-ios/
• More players in this space, esp. for enterprises...
98. TestFlight Config
• API Token and Team Token
• Need a signed IPA
• They get an email with a link for OTA
installation!
100. Protect Your Tokens
• API Token & Team Token
• Keep them out of scripts
• Instead, define them in Jenkins (and leverage
Jenkins security)
• 'Configure System'
• 'Global properties' section
• Or use the plugin (same parameters)
114. Other Goodies
• Ensure your site or API is up
• Scan your code for TODOs and FIXMEs
• Get trend reports for lines of code
(SLOCCount w/ sloc2html)
• Scan for duplicated blocks of code (CPD,
Simian, etc.)
• Use agvtool (Apple-Generic Versioning
Tool) to increment your build number
115.
116.
117. Still Missing
• Cyclomatic Complexity
• Coding convention/Style checker
• Code Formatter
• Uncrustify, UniversalIndentGUI
• UML Generation
• via CLI, as opposed to OmniGraffle (AppleScript?)
• ER Diagram from Core Data schema