Date post: | 10-May-2015 |
Category: |
Technology |
Upload: | cloudbees |
View: | 2,454 times |
Download: | 6 times |
Automated Testing and Continuous Deployment for Mobile Apps with Jenkins
Kohsuke Kawaguchi and Mark Prichard, CloudBeesMatt Solnit, SOASTAAugust 30, 2012
@CloudBees, @CloudTest, @NewRelic
2
Have you met Jenkins?
• #1 OSS CI server–Written in Java
• About 7 years old• Easy to install/use• Extensible via 550+ plugins• Widely adopted– 43K+ installations
• Kohsuke is Jenkins creator/project lead
3
• To let developers focus on developing– Leave building, packaging, testing, distributing
to a computer– Make the right thing the easiest thing
• Many, well-adopted mobile development plugins– Safety in numbers
• “Distributed builds” for scaling with workload
• “Matrix project” for easy cross device testing
Why Jenkins for mobile development?
4
• Appaloosa plugin, TestFlight plugin– continuous app distribution
• Xcode plugin– Better UI for xcode command
invocations
More iOS+Jenkins love we won’t cover
5
• Android emulator plugin– For running tests inside emulator in
Jenkins
• Android lint plugin– Parses & visualizes the result of static
analysis
• Zubhium plugin– Continuous app distribution
We got Android covered, too
6
• Some apps don’t need external data• But most do– Push notifications– Location information– Twitter, news feeds– Social interaction– Integration
What makes a great mobile app?
7
StockFish … … or Social Chess?
Standalone … … or Integrated?
Two Five-Star Apps
or BOTH?
8
• The basics: record games, moves• Next steps: notifications, time keeping • Going further: competition, research• Chess client apps handle actual play• Server doesn’t need to know the rules
• Just for fun: https://github.com/mqprichard/mongo-chess
Building a “Social” Chess Server
9
• Built using Eclipse, Maven, Junit, JAX-RS, JAX-B, gson …
• Git repository, Jenkins build/test and app deployment all running on AWS using CloudBees PaaS
• Free to develop: enterprise-grade runtime services
Fun App – but ‘Real’ Java Development
10
• Suppose I add some new killer feature• What do I need to test?– Do all components build correctly?– Do the unit tests pass?– Did the interfaces change?– Have I affected the UI behavior?
• I need this all to happen continuously and automatically – end-to-end testing
Testing, Testing, Testing
11
Jenkins to the Rescue
Jenkins
iOS Development (Xcode)
Services Development
(Eclipse)
Services Deployment
iOS Packaging/Distrib
ution
Services Build/Unit Test
iOS App Build/Unit Test
Integration/Functional
Testing
iOS TouchTest
Source Code Repository
12
• iOS App built from GitHub/CloudBees Forge– Jenkins Xcode builds/tests run on MacOS slaves– Scripted integration tests– Automated functional tests (SOASTA)– Automated gesture-aware touch tests (SOASTA)– iOS app archive/packaging/distribution all
managed through Jenkins plug-ins
• Back-end services end-to-end deployment– Build/Test/Deploy using Eclipse/CloudBees
What you will see
13
Jenkins and Agile CI Best Practices
MonitorRepository
Build Code
Test Code
StageApplication
ContinuousDeployment
Continuous Integration The Key to Agile and Lean Development
• Better quality
products
• Faster delivery
• Scale teams
14
Jenkins and Agile CI Best Practices
©2012 CloudBees, Inc. All Rights Reserved
MonitorRepository
Build Code
Test Code
StageApplication
ContinuousDeployment
Jenkins in the CloudThe Key to Agile and Lean Development
• Unlimited
scalability
• Use what you need
• Seamless tie-in to
PaaS
15
• It’s totally free for developers• One click and we’ll start you off with
Jenkins, Java, Scala/Lift, MySQL and more
www.cloudbees.com/signup
Sign Up with CloudBees
16
Jenkins User Conference, San Francisco Sept 30, 2012
Kohsuke Kawaguchitwitter: @kohsukekawaemail: [email protected]
Mark Prichardtwitter: @mqprichard email: [email protected]
Matt Solnittwitter: @msolnitemail: [email protected]
Thank You – See you in San Francisco!