Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Getting Groovy with iOS Development

Getting Groovy with iOS Development

My talk at GR8ConfUS 2015 that focusses on using tools from the groovy ecosystem for making iOS development easier.

Rahul Somasunderam

July 30, 2015
Tweet

More Decks by Rahul Somasunderam

Other Decks in Programming

Transcript

  1. Where I work • We build a Health Information Exchange

    Population Health Tools • Used by 130 Health Systems, 600 Hospitals, 20K physicians • We love Groovy
  2. Tools • XCode bad. AppCode good • Objective-C and Swift

    • Dependency Management • Build Tools • Functional Testing
  3. • Your app needs dependencies • Dependencies can be installed

    with Cocoapods • Cocoapods is a ruby gem • Ruby gems can be installed with Bundler • You WANT ruby in the user space; so RBENV • There is a brew formula for RBENV • brew is installed using system ruby
  4. xcodebuild xcodebuild \ -scheme Todos \ -workspace Todos.xcworkspace \ -sdk

    iphonesimulator \ -configuration Debug \ DSTROOT=/Users/rahul/src/Todos/build/dst \ OBJROOT=/Users/rahul/src/Todos/build/obj \ SYMROOT=/Users/rahul/src/Todos/build/sym \ SHARED_PRECOMPS_DIR=/Users/rahul/src/Todos/build/shared \ -destination 'platform=iOS Simulator,id=CAB835ED-3EE2-47B6-AD74-C06675651CEF' \ test
  5. xcodebuild • Too complex commands - Unruly bash scripts •

    Different tools for build, upload to testflight, hockeyapp • Very little documentation, very steep learning curve • What about functional testing?
  6. xctool • Written in Objective-C • Needs advanced knowledge of

    Objective-C • What about functional testing?
  7. Nomad CLI • Written in ruby • Great support for

    certificates, distribution profiles • Great support for distribution using iTunesConnect • What about functional testing?
  8. What we need • Flexible build system • Support for

    distribution • Support for functional testing • Easy to install, even if you're an enterprise software company • Easy to run
  9. Gradle Xcode Plugin buildscript { repositories { maven { url

    "https://plugins.gradle.org/m2/" } } dependencies { classpath "gradle.plugin.org.openbakery:xcodePlugin:0.11.3" } } ! apply plugin: "org.openbakery.xcodeplugin" ! xcodebuild { workspace = 'Todos.xcworkspace' scheme = 'Todos' target = 'Todos' sdk = 'iphonesimulator' }
  10. • gradle xcodetest • gradle hockeyapp • gradle deploygate •

    gradle appstoreUpload • gradle oclint • gradle cpd • gradle crashlytics
  11. UIAutomation using Instruments • Record and Playback • DOM Tree

    access • Refactoring • Managing State • Tuneup JS? Bwoken?
  12. Appium • Based on Selenium • Clients for several languages

    including Java • Makes your app stateless