ºÝºÝߣ

ºÝºÝߣShare a Scribd company logo
Build Automation for Mobile 
or 
How to Deliver Quality Apps Continiously 
Angelo R¨¹ggeberg
2 
Things to remember 
?Publishing your App should not be 
painfull¡° 
Angelo R¨¹ggeberg 
?Code Quality Matters¡° 
Angelo R¨¹ggeberg
3 
Who am I? 
? Mobile Development 
? Android 
? iOS 
? Backend 
? Cloud Infrastructure 
http://plus.google.com/+AngeloR¨¹ggeberg 
http://s3xy4ngyc.github.io/ s3xy4ngyc
4 
Release Process 
Current Situation
5 
Release Process 
Current Situation
6 
Release Process 
the future 
Everything you have to do afterwards is 
git push
7 
Release Process 
the future
8 
Build Automation 
What will we be using 
jenkins 
Test Driven Development 
Git 
Beta Distribution 
Nightly Versions 
Gradle
9 
Build Automation 
Benefits 
? New Features are Live ASAP 
? As Soon As Pushed 
? Only Stable and Tested Builds can be Pushed 
? No more unstable Releases 
? Less Human Testing 
? No more Sharing of Sensitive Data 
? Keystores 
? Logins
10 
Build Automation 
Jenkins 
Jenkins is an award-winning application that monitors executions of repeated jobs, such as ? Building/testing software projects continuously 
? Monitoring executions of externally-run jobs 
Get Jenkins at: http://jenkins-ci.org/
11 
Build Automation 
Build Pipeline 
? Sample Build Pipeline: 
compile 
lint 
Tests 
sonar 
monkey 
runner 
distribute
12 
Build Automation 
Build Pipeline 
? Distribution will only Happen if all Previous Steps Succeed 
? Tests, Code Analysis, etc. can Run Parallel 
? Step by Step enables Failing Fast 
? Resource Hungry Jobs like Monkey Runner will be triggered only if needed
13 
Jenkins 
Usefull Tipps 
? Clone Workspace SCM Plugin 
? Shared Workspaces may have locks 
? https://wiki.jenkins-ci.org/display/JENKINS/Clone+Workspace+SCM+Plugin 
? Polling Sucks 
? use Git Hooks! 
? Do not run on a Small Virtual Machine 
? Android Emulator needs some Hardware 
? Intel HAX strongly Recommended!
14 
Jenkins 
Build Monitor Plugin
15 
Jenkins 
Build Pipeline View Plugin
16 
Jenkins 
Monitoring Plugins
17 
Build Automation 
gradle 
? Best of ANT / Maven / GANT / Ivy 
? Based on Groovy Scripts 
? Expressive DSL 
? (Flexible) Convention over Configuration 
? Easy to extend 
? ?Make the impossible possible, make the possible easy 
and make the easy elegant.¡±
18 
gradle 
flavoring 
? Staging, Dev and Live Packages 
? On Your Test Device no Constant Uninstalling 
? Adjustable Configurations without Code Changes 
? Why? 
? Reproduce able builds, easy setup
19 
gradle 
sample Code
20 
gradle 
sample Code 
Project Setup Flavoring 
? Same Folder Structure for 
every Flavor 
? Flavor Specific files Overwrite 
Files from Main 
? Only Overwrite What your 
Flavor Needs 
? Flavor Only Files Possible
21 
gradle 
sample Code 
Example Flavor Specific Manifest 
? Only Provider defined 
? Everything else comes from main/AndroidManifest.xml
22 
Build Automation 
git 
? Branching 
? Opensource 
? Integrated and Extended Implementations
23 
Git 
Git Workflow 
Git Flow Branching Model 
source: www.atlassian.com
24 
Jenkins 
Git Flow and Jenkins Examples 
? Staging 
? Hook on develop Branch 
? Nightly 
? Time Based Build (eg once a day at 0 AM) 
? builds newest feature Branch 
? Live 
? Only Builds release Tags 
? Release Notes are Tag Message
25 
Beta Test Distribution
26 
Beta Test Distribution 
Examples 
? Google Play 
? Alpha / Channel 
? Works on every Device that has The Playstore 
? Crashlytics 
? Distribution Groups & User Level 
? gradle Integration 
? free 
? HokeyApp 
? Comercial
27 
Unit Testing 
WHY? 
Testing - Do it
28 
Unit Testing 
WHY?
29 
Unit Testing 
WHY? 
? Code Quality Matters! 
? Insurance everything still works 
? As it should be working 
? Refactoring made easy 
? Unittests are somehow a Functional Documentation
30 
Unit Testing 
Some Tipps: 
? Tests first! 
? Simplest and dumbest way to implement 
? Test Orientation Changes 
? Test State Changes 
? Lock Screen 
? Incoming calls 
? etc. 
? Check Code Coverage
31 
Test Frameworks 
Unittests 
? Robolectric 
? No Emulator Needed 
? No Mocking Frameworks Needed 
? API Level Emulation only up to 18 (currently) 
? Robotium 
? Silenium for Android 
? User Scenarios 
? Default Android Testing Framework
32 
Test Frameworks 
UI Testing 
? Espresso 
? Ui Testing 
? Double Espresso 
? Espresso Gradle Port 
? Ui Automator 
? Android Default UI Testing Framework
33 
Mocking
34 
Test Frameworks 
Device Testing 
Distributing instrumentation tests 
http://square.github.io/spoon/
35 
Test Frameworks 
Device Testing
36 
Test Frameworks 
Device Testing
37 
Test Frameworks 
Device Testing
38 
Build Automation 
Measure Code Quality 
? Measure Code Quality over Time 
Duplicated code 
? Coding standards 
? Unit tests 
? Complex code 
? Potential bugs 
? Comments 
? Design and architecture
39 
Test Frameworks 
Code Coverage
40 
Test Frameworks 
Code Coverage
41 
Build Automation 
Static Code Analysis
42 
Build Automation 
Static Code Analysis 
? Testing your Application makes your life more Stress free 
? Code Quality 
? Less Production Crashes 
? Don¡¯t develop Stuff that should not go live 
? Use Gradle Flavors!
43 
Build Automation 
Final Thoughts 
? Testing your Application makes your life more Stress free 
? Code Quality 
? Less Production Crashes 
? Don¡¯t develop Stuff that should not go live 
? DONE = RELEASED 
? Use Gradle Flavors!
44 
Release Process 
the future
>> /etc/

More Related Content

What's hot (20)

Java Test Automation for REST, Web and Mobile
Java Test Automation for REST, Web and MobileJava Test Automation for REST, Web and Mobile
Java Test Automation for REST, Web and Mobile
Elias Nogueira
?
Trust Your Pipeline - Automatically Testing and End-to-End Java Application
Trust Your Pipeline - Automatically Testing and End-to-End Java ApplicationTrust Your Pipeline - Automatically Testing and End-to-End Java Application
Trust Your Pipeline - Automatically Testing and End-to-End Java Application
Elias Nogueira
?
Testing desktop apps with selenium
Testing desktop apps with seleniumTesting desktop apps with selenium
Testing desktop apps with selenium
Filip Braun
?
Tips for better CI on Android
Tips for better CI on AndroidTips for better CI on Android
Tips for better CI on Android
Tomoaki Imai
?
Behat sauce
Behat sauceBehat sauce
Behat sauce
Shashikant Jagtap
?
Building the Test Automation Framework - Jenkins for Testers
Building the Test Automation Framework - Jenkins for TestersBuilding the Test Automation Framework - Jenkins for Testers
Building the Test Automation Framework - Jenkins for Testers
William Echlin
?
DevOps ¼° TDD é_°lÁ÷³ÌÕÜŒW
DevOps ¼° TDD é_°lÁ÷³ÌÕÜŒWDevOps ¼° TDD é_°lÁ÷³ÌÕÜŒW
DevOps ¼° TDD é_°lÁ÷³ÌÕÜŒW
Öx ×Ú·f
?
Midwest PHP 2017 DevOps For Small team
Midwest PHP 2017 DevOps For Small teamMidwest PHP 2017 DevOps For Small team
Midwest PHP 2017 DevOps For Small team
Joe Ferguson
?
Deploy your app with one Slack command
Deploy your app with one Slack commandDeploy your app with one Slack command
Deploy your app with one Slack command
Fabio Milano
?
GitHub Actions for 5 minutes
GitHub Actions for 5 minutesGitHub Actions for 5 minutes
GitHub Actions for 5 minutes
Svetlin Nakov
?
Build 2017 - B8093 - Nextgen UWP app distribution: Building extensible, strea...
Build 2017 - B8093 - Nextgen UWP app distribution: Building extensible, strea...Build 2017 - B8093 - Nextgen UWP app distribution: Building extensible, strea...
Build 2017 - B8093 - Nextgen UWP app distribution: Building extensible, strea...
Windows Developer
?
Continuous Delivery for Front-End Engineers
Continuous Delivery for Front-End EngineersContinuous Delivery for Front-End Engineers
Continuous Delivery for Front-End Engineers
Sergey Bolshchikov
?
Speed up your Titanium app development with automated tests - TiConf EU 2014
Speed up your Titanium app development with automated tests - TiConf EU 2014Speed up your Titanium app development with automated tests - TiConf EU 2014
Speed up your Titanium app development with automated tests - TiConf EU 2014
Emanuele Rampichini
?
BDD using Behat, Selenium,Sahi and SauceLabs
BDD using Behat, Selenium,Sahi and SauceLabsBDD using Behat, Selenium,Sahi and SauceLabs
BDD using Behat, Selenium,Sahi and SauceLabs
Shashikant Jagtap
?
Modern infrastructure as code with ansible cake fest 2021
Modern infrastructure as code with ansible cake fest 2021Modern infrastructure as code with ansible cake fest 2021
Modern infrastructure as code with ansible cake fest 2021
Joe Ferguson
?
Continuous integration in games development
Continuous integration in games developmentContinuous integration in games development
Continuous integration in games development
Nebojsa Brindic
?
Slim PHP when you don't need the kitchen sink
Slim PHP   when you don't need the kitchen sinkSlim PHP   when you don't need the kitchen sink
Slim PHP when you don't need the kitchen sink
Joe Ferguson
?
Graphql usage
Graphql usageGraphql usage
Graphql usage
Valentin Buryakov
?
BDD with Behat Selenium, Sahi and Sauce
BDD with Behat Selenium, Sahi and SauceBDD with Behat Selenium, Sahi and Sauce
BDD with Behat Selenium, Sahi and Sauce
Shashikant Jagtap
?
Automated UI Testing Frameworks
Automated UI Testing FrameworksAutomated UI Testing Frameworks
Automated UI Testing Frameworks
TestObject - Mobile Testing
?
Java Test Automation for REST, Web and Mobile
Java Test Automation for REST, Web and MobileJava Test Automation for REST, Web and Mobile
Java Test Automation for REST, Web and Mobile
Elias Nogueira
?
Trust Your Pipeline - Automatically Testing and End-to-End Java Application
Trust Your Pipeline - Automatically Testing and End-to-End Java ApplicationTrust Your Pipeline - Automatically Testing and End-to-End Java Application
Trust Your Pipeline - Automatically Testing and End-to-End Java Application
Elias Nogueira
?
Testing desktop apps with selenium
Testing desktop apps with seleniumTesting desktop apps with selenium
Testing desktop apps with selenium
Filip Braun
?
Tips for better CI on Android
Tips for better CI on AndroidTips for better CI on Android
Tips for better CI on Android
Tomoaki Imai
?
Building the Test Automation Framework - Jenkins for Testers
Building the Test Automation Framework - Jenkins for TestersBuilding the Test Automation Framework - Jenkins for Testers
Building the Test Automation Framework - Jenkins for Testers
William Echlin
?
DevOps ¼° TDD é_°lÁ÷³ÌÕÜŒW
DevOps ¼° TDD é_°lÁ÷³ÌÕÜŒWDevOps ¼° TDD é_°lÁ÷³ÌÕÜŒW
DevOps ¼° TDD é_°lÁ÷³ÌÕÜŒW
Öx ×Ú·f
?
Midwest PHP 2017 DevOps For Small team
Midwest PHP 2017 DevOps For Small teamMidwest PHP 2017 DevOps For Small team
Midwest PHP 2017 DevOps For Small team
Joe Ferguson
?
Deploy your app with one Slack command
Deploy your app with one Slack commandDeploy your app with one Slack command
Deploy your app with one Slack command
Fabio Milano
?
GitHub Actions for 5 minutes
GitHub Actions for 5 minutesGitHub Actions for 5 minutes
GitHub Actions for 5 minutes
Svetlin Nakov
?
Build 2017 - B8093 - Nextgen UWP app distribution: Building extensible, strea...
Build 2017 - B8093 - Nextgen UWP app distribution: Building extensible, strea...Build 2017 - B8093 - Nextgen UWP app distribution: Building extensible, strea...
Build 2017 - B8093 - Nextgen UWP app distribution: Building extensible, strea...
Windows Developer
?
Continuous Delivery for Front-End Engineers
Continuous Delivery for Front-End EngineersContinuous Delivery for Front-End Engineers
Continuous Delivery for Front-End Engineers
Sergey Bolshchikov
?
Speed up your Titanium app development with automated tests - TiConf EU 2014
Speed up your Titanium app development with automated tests - TiConf EU 2014Speed up your Titanium app development with automated tests - TiConf EU 2014
Speed up your Titanium app development with automated tests - TiConf EU 2014
Emanuele Rampichini
?
BDD using Behat, Selenium,Sahi and SauceLabs
BDD using Behat, Selenium,Sahi and SauceLabsBDD using Behat, Selenium,Sahi and SauceLabs
BDD using Behat, Selenium,Sahi and SauceLabs
Shashikant Jagtap
?
Modern infrastructure as code with ansible cake fest 2021
Modern infrastructure as code with ansible cake fest 2021Modern infrastructure as code with ansible cake fest 2021
Modern infrastructure as code with ansible cake fest 2021
Joe Ferguson
?
Continuous integration in games development
Continuous integration in games developmentContinuous integration in games development
Continuous integration in games development
Nebojsa Brindic
?
Slim PHP when you don't need the kitchen sink
Slim PHP   when you don't need the kitchen sinkSlim PHP   when you don't need the kitchen sink
Slim PHP when you don't need the kitchen sink
Joe Ferguson
?
BDD with Behat Selenium, Sahi and Sauce
BDD with Behat Selenium, Sahi and SauceBDD with Behat Selenium, Sahi and Sauce
BDD with Behat Selenium, Sahi and Sauce
Shashikant Jagtap
?

Similar to Build Automation in Android (20)

iOS Indie Developer Toolkit - CocoaHeads 3city
iOS Indie Developer Toolkit - CocoaHeads 3cityiOS Indie Developer Toolkit - CocoaHeads 3city
iOS Indie Developer Toolkit - CocoaHeads 3city
Micha? Zygar
?
LF_APIStrat17_Super-Powered REST API Testing
LF_APIStrat17_Super-Powered REST API TestingLF_APIStrat17_Super-Powered REST API Testing
LF_APIStrat17_Super-Powered REST API Testing
LF_APIStrat
?
Continuously Break The Android
Continuously Break The AndroidContinuously Break The Android
Continuously Break The Android
Hasan Hosgel
?
2013-03-07 indie developer toolkit
2013-03-07 indie developer toolkit2013-03-07 indie developer toolkit
2013-03-07 indie developer toolkit
CocoaHeads Tricity
?
High Performance Software Engineering Teams
High Performance Software Engineering TeamsHigh Performance Software Engineering Teams
High Performance Software Engineering Teams
Lars Thorup
?
Software Factory - Overview
Software Factory - OverviewSoftware Factory - Overview
Software Factory - Overview
slides_teltools
?
Continuous inspection with Sonar
Continuous inspection with SonarContinuous inspection with Sonar
Continuous inspection with Sonar
gaudol
?
Expedia 3x3 presentation
Expedia 3x3 presentationExpedia 3x3 presentation
Expedia 3x3 presentation
Drew Hannay
?
Headless browser: puppeteer and git client : GitKraken
Headless browser: puppeteer and git client : GitKrakenHeadless browser: puppeteer and git client : GitKraken
Headless browser: puppeteer and git client : GitKraken
SheikhMoonwaraAnjumM
?
Webinar - Unbox GitLab CI/CD
Webinar - Unbox GitLab CI/CD Webinar - Unbox GitLab CI/CD
Webinar - Unbox GitLab CI/CD
Annie Huang
?
Head first android apps dev tools
Head first android apps dev toolsHead first android apps dev tools
Head first android apps dev tools
Shaka Huang
?
Creating a reasonable project boilerplate
Creating a reasonable project boilerplateCreating a reasonable project boilerplate
Creating a reasonable project boilerplate
Stanislav Petrov
?
Gitlab meets Kubernetes
Gitlab meets KubernetesGitlab meets Kubernetes
Gitlab meets Kubernetes
inovex GmbH
?
Building High Quality Android Applications
Building High Quality Android ApplicationsBuilding High Quality Android Applications
Building High Quality Android Applications
Leif Janzik
?
Selenium Israel Meetup
Selenium Israel MeetupSelenium Israel Meetup
Selenium Israel Meetup
Justin Ison
?
Ci of js and apex using jasmine, phantom js and drone io df14
Ci of js and apex using jasmine, phantom js and drone io   df14Ci of js and apex using jasmine, phantom js and drone io   df14
Ci of js and apex using jasmine, phantom js and drone io df14
Kevin Poorman
?
Continuous mobile automation in build pipeline
Continuous mobile automation in build pipelineContinuous mobile automation in build pipeline
Continuous mobile automation in build pipeline
dm l
?
Effective Android Development. UA Mobile 2016.
Effective Android Development. UA Mobile 2016.Effective Android Development. UA Mobile 2016.
Effective Android Development. UA Mobile 2016.
UA Mobile
?
Continuous Integration/Deployment with Gitlab CI
Continuous Integration/Deployment with Gitlab CIContinuous Integration/Deployment with Gitlab CI
Continuous Integration/Deployment with Gitlab CI
David Hahn
?
GitLab's Acquisition Strategy & Approach
GitLab's Acquisition Strategy & ApproachGitLab's Acquisition Strategy & Approach
GitLab's Acquisition Strategy & Approach
Eliran Mesika
?
iOS Indie Developer Toolkit - CocoaHeads 3city
iOS Indie Developer Toolkit - CocoaHeads 3cityiOS Indie Developer Toolkit - CocoaHeads 3city
iOS Indie Developer Toolkit - CocoaHeads 3city
Micha? Zygar
?
LF_APIStrat17_Super-Powered REST API Testing
LF_APIStrat17_Super-Powered REST API TestingLF_APIStrat17_Super-Powered REST API Testing
LF_APIStrat17_Super-Powered REST API Testing
LF_APIStrat
?
Continuously Break The Android
Continuously Break The AndroidContinuously Break The Android
Continuously Break The Android
Hasan Hosgel
?
2013-03-07 indie developer toolkit
2013-03-07 indie developer toolkit2013-03-07 indie developer toolkit
2013-03-07 indie developer toolkit
CocoaHeads Tricity
?
High Performance Software Engineering Teams
High Performance Software Engineering TeamsHigh Performance Software Engineering Teams
High Performance Software Engineering Teams
Lars Thorup
?
Software Factory - Overview
Software Factory - OverviewSoftware Factory - Overview
Software Factory - Overview
slides_teltools
?
Continuous inspection with Sonar
Continuous inspection with SonarContinuous inspection with Sonar
Continuous inspection with Sonar
gaudol
?
Expedia 3x3 presentation
Expedia 3x3 presentationExpedia 3x3 presentation
Expedia 3x3 presentation
Drew Hannay
?
Headless browser: puppeteer and git client : GitKraken
Headless browser: puppeteer and git client : GitKrakenHeadless browser: puppeteer and git client : GitKraken
Headless browser: puppeteer and git client : GitKraken
SheikhMoonwaraAnjumM
?
Webinar - Unbox GitLab CI/CD
Webinar - Unbox GitLab CI/CD Webinar - Unbox GitLab CI/CD
Webinar - Unbox GitLab CI/CD
Annie Huang
?
Head first android apps dev tools
Head first android apps dev toolsHead first android apps dev tools
Head first android apps dev tools
Shaka Huang
?
Creating a reasonable project boilerplate
Creating a reasonable project boilerplateCreating a reasonable project boilerplate
Creating a reasonable project boilerplate
Stanislav Petrov
?
Gitlab meets Kubernetes
Gitlab meets KubernetesGitlab meets Kubernetes
Gitlab meets Kubernetes
inovex GmbH
?
Building High Quality Android Applications
Building High Quality Android ApplicationsBuilding High Quality Android Applications
Building High Quality Android Applications
Leif Janzik
?
Selenium Israel Meetup
Selenium Israel MeetupSelenium Israel Meetup
Selenium Israel Meetup
Justin Ison
?
Ci of js and apex using jasmine, phantom js and drone io df14
Ci of js and apex using jasmine, phantom js and drone io   df14Ci of js and apex using jasmine, phantom js and drone io   df14
Ci of js and apex using jasmine, phantom js and drone io df14
Kevin Poorman
?
Continuous mobile automation in build pipeline
Continuous mobile automation in build pipelineContinuous mobile automation in build pipeline
Continuous mobile automation in build pipeline
dm l
?
Effective Android Development. UA Mobile 2016.
Effective Android Development. UA Mobile 2016.Effective Android Development. UA Mobile 2016.
Effective Android Development. UA Mobile 2016.
UA Mobile
?
Continuous Integration/Deployment with Gitlab CI
Continuous Integration/Deployment with Gitlab CIContinuous Integration/Deployment with Gitlab CI
Continuous Integration/Deployment with Gitlab CI
David Hahn
?
GitLab's Acquisition Strategy & Approach
GitLab's Acquisition Strategy & ApproachGitLab's Acquisition Strategy & Approach
GitLab's Acquisition Strategy & Approach
Eliran Mesika
?

Recently uploaded (20)

Lecture -3 Cold water supply system.pptx
Lecture -3 Cold water supply system.pptxLecture -3 Cold water supply system.pptx
Lecture -3 Cold water supply system.pptx
rabiaatif2
?
Structural QA/QC Inspection in KRP 401600 | Copper Processing Plant-3 (MOF-3)...
Structural QA/QC Inspection in KRP 401600 | Copper Processing Plant-3 (MOF-3)...Structural QA/QC Inspection in KRP 401600 | Copper Processing Plant-3 (MOF-3)...
Structural QA/QC Inspection in KRP 401600 | Copper Processing Plant-3 (MOF-3)...
slayshadow705
?
How to Make an RFID Door Lock System using Arduino
How to Make an RFID Door Lock System using ArduinoHow to Make an RFID Door Lock System using Arduino
How to Make an RFID Door Lock System using Arduino
CircuitDigest
?
US Patented ReGenX Generator, ReGen-X Quatum Motor EV Regenerative Accelerati...
US Patented ReGenX Generator, ReGen-X Quatum Motor EV Regenerative Accelerati...US Patented ReGenX Generator, ReGen-X Quatum Motor EV Regenerative Accelerati...
US Patented ReGenX Generator, ReGen-X Quatum Motor EV Regenerative Accelerati...
Thane Heins NOBEL PRIZE WINNING ENERGY RESEARCHER
?
Integration of Additive Manufacturing (AM) with IoT : A Smart Manufacturing A...
Integration of Additive Manufacturing (AM) with IoT : A Smart Manufacturing A...Integration of Additive Manufacturing (AM) with IoT : A Smart Manufacturing A...
Integration of Additive Manufacturing (AM) with IoT : A Smart Manufacturing A...
ASHISHDESAI85
?
Embedded System intro Embedded System intro.ppt
Embedded System intro Embedded System intro.pptEmbedded System intro Embedded System intro.ppt
Embedded System intro Embedded System intro.ppt
23ucc580
?
Cloud Computing concepts and technologies
Cloud Computing concepts and technologiesCloud Computing concepts and technologies
Cloud Computing concepts and technologies
ssuser4c9444
?
Industrial Valves, Instruments Products Profile
Industrial Valves, Instruments Products ProfileIndustrial Valves, Instruments Products Profile
Industrial Valves, Instruments Products Profile
zebcoeng
?
Wireless-Charger presentation for seminar .pdf
Wireless-Charger presentation for seminar .pdfWireless-Charger presentation for seminar .pdf
Wireless-Charger presentation for seminar .pdf
AbhinandanMishra30
?
decarbonization steel industry rev1.pptx
decarbonization steel industry rev1.pptxdecarbonization steel industry rev1.pptx
decarbonization steel industry rev1.pptx
gonzalezolabarriaped
?
Cyber Security_ Protecting the Digital World.pptx
Cyber Security_ Protecting the Digital World.pptxCyber Security_ Protecting the Digital World.pptx
Cyber Security_ Protecting the Digital World.pptx
Harshith A S
?
Frankfurt University of Applied Science urkunde
Frankfurt University of Applied Science urkundeFrankfurt University of Applied Science urkunde
Frankfurt University of Applied Science urkunde
Lisa Emerson
?
Indian Soil Classification System in Geotechnical Engineering
Indian Soil Classification System in Geotechnical EngineeringIndian Soil Classification System in Geotechnical Engineering
Indian Soil Classification System in Geotechnical Engineering
Rajani Vyawahare
?
CS3451-OPERATING-SYSTEM NOTES ALL123.pdf
CS3451-OPERATING-SYSTEM NOTES ALL123.pdfCS3451-OPERATING-SYSTEM NOTES ALL123.pdf
CS3451-OPERATING-SYSTEM NOTES ALL123.pdf
PonniS7
?
Mathematics behind machine learning INT255 INT255__Unit 3__PPT-1.pptx
Mathematics behind machine learning INT255 INT255__Unit 3__PPT-1.pptxMathematics behind machine learning INT255 INT255__Unit 3__PPT-1.pptx
Mathematics behind machine learning INT255 INT255__Unit 3__PPT-1.pptx
ppkmurthy2006
?
GROUP-3-GRID-CODE-AND-DISTRIBUTION-CODE.pptx
GROUP-3-GRID-CODE-AND-DISTRIBUTION-CODE.pptxGROUP-3-GRID-CODE-AND-DISTRIBUTION-CODE.pptx
GROUP-3-GRID-CODE-AND-DISTRIBUTION-CODE.pptx
meneememoo
?
CFOT Fiber Optics FOA CERTIFICATION.pptx
CFOT Fiber Optics FOA CERTIFICATION.pptxCFOT Fiber Optics FOA CERTIFICATION.pptx
CFOT Fiber Optics FOA CERTIFICATION.pptx
MohamedShabana37
?
Best KNow Hydrogen Fuel Production in the World The cost in USD kwh for H2
Best KNow  Hydrogen Fuel Production in the World The cost in USD kwh for H2Best KNow  Hydrogen Fuel Production in the World The cost in USD kwh for H2
Best KNow Hydrogen Fuel Production in the World The cost in USD kwh for H2
Daniel Donatelli
?
only history of java.pptx real bihind the name java
only history of java.pptx real bihind the name javaonly history of java.pptx real bihind the name java
only history of java.pptx real bihind the name java
mushtaqsaliq9
?
Introduction to Safety, Health & Environment
Introduction to Safety, Health  & EnvironmentIntroduction to Safety, Health  & Environment
Introduction to Safety, Health & Environment
ssuserc606c7
?
Lecture -3 Cold water supply system.pptx
Lecture -3 Cold water supply system.pptxLecture -3 Cold water supply system.pptx
Lecture -3 Cold water supply system.pptx
rabiaatif2
?
Structural QA/QC Inspection in KRP 401600 | Copper Processing Plant-3 (MOF-3)...
Structural QA/QC Inspection in KRP 401600 | Copper Processing Plant-3 (MOF-3)...Structural QA/QC Inspection in KRP 401600 | Copper Processing Plant-3 (MOF-3)...
Structural QA/QC Inspection in KRP 401600 | Copper Processing Plant-3 (MOF-3)...
slayshadow705
?
How to Make an RFID Door Lock System using Arduino
How to Make an RFID Door Lock System using ArduinoHow to Make an RFID Door Lock System using Arduino
How to Make an RFID Door Lock System using Arduino
CircuitDigest
?
Integration of Additive Manufacturing (AM) with IoT : A Smart Manufacturing A...
Integration of Additive Manufacturing (AM) with IoT : A Smart Manufacturing A...Integration of Additive Manufacturing (AM) with IoT : A Smart Manufacturing A...
Integration of Additive Manufacturing (AM) with IoT : A Smart Manufacturing A...
ASHISHDESAI85
?
Embedded System intro Embedded System intro.ppt
Embedded System intro Embedded System intro.pptEmbedded System intro Embedded System intro.ppt
Embedded System intro Embedded System intro.ppt
23ucc580
?
Cloud Computing concepts and technologies
Cloud Computing concepts and technologiesCloud Computing concepts and technologies
Cloud Computing concepts and technologies
ssuser4c9444
?
Industrial Valves, Instruments Products Profile
Industrial Valves, Instruments Products ProfileIndustrial Valves, Instruments Products Profile
Industrial Valves, Instruments Products Profile
zebcoeng
?
Wireless-Charger presentation for seminar .pdf
Wireless-Charger presentation for seminar .pdfWireless-Charger presentation for seminar .pdf
Wireless-Charger presentation for seminar .pdf
AbhinandanMishra30
?
decarbonization steel industry rev1.pptx
decarbonization steel industry rev1.pptxdecarbonization steel industry rev1.pptx
decarbonization steel industry rev1.pptx
gonzalezolabarriaped
?
Cyber Security_ Protecting the Digital World.pptx
Cyber Security_ Protecting the Digital World.pptxCyber Security_ Protecting the Digital World.pptx
Cyber Security_ Protecting the Digital World.pptx
Harshith A S
?
Frankfurt University of Applied Science urkunde
Frankfurt University of Applied Science urkundeFrankfurt University of Applied Science urkunde
Frankfurt University of Applied Science urkunde
Lisa Emerson
?
Indian Soil Classification System in Geotechnical Engineering
Indian Soil Classification System in Geotechnical EngineeringIndian Soil Classification System in Geotechnical Engineering
Indian Soil Classification System in Geotechnical Engineering
Rajani Vyawahare
?
CS3451-OPERATING-SYSTEM NOTES ALL123.pdf
CS3451-OPERATING-SYSTEM NOTES ALL123.pdfCS3451-OPERATING-SYSTEM NOTES ALL123.pdf
CS3451-OPERATING-SYSTEM NOTES ALL123.pdf
PonniS7
?
Mathematics behind machine learning INT255 INT255__Unit 3__PPT-1.pptx
Mathematics behind machine learning INT255 INT255__Unit 3__PPT-1.pptxMathematics behind machine learning INT255 INT255__Unit 3__PPT-1.pptx
Mathematics behind machine learning INT255 INT255__Unit 3__PPT-1.pptx
ppkmurthy2006
?
GROUP-3-GRID-CODE-AND-DISTRIBUTION-CODE.pptx
GROUP-3-GRID-CODE-AND-DISTRIBUTION-CODE.pptxGROUP-3-GRID-CODE-AND-DISTRIBUTION-CODE.pptx
GROUP-3-GRID-CODE-AND-DISTRIBUTION-CODE.pptx
meneememoo
?
CFOT Fiber Optics FOA CERTIFICATION.pptx
CFOT Fiber Optics FOA CERTIFICATION.pptxCFOT Fiber Optics FOA CERTIFICATION.pptx
CFOT Fiber Optics FOA CERTIFICATION.pptx
MohamedShabana37
?
Best KNow Hydrogen Fuel Production in the World The cost in USD kwh for H2
Best KNow  Hydrogen Fuel Production in the World The cost in USD kwh for H2Best KNow  Hydrogen Fuel Production in the World The cost in USD kwh for H2
Best KNow Hydrogen Fuel Production in the World The cost in USD kwh for H2
Daniel Donatelli
?
only history of java.pptx real bihind the name java
only history of java.pptx real bihind the name javaonly history of java.pptx real bihind the name java
only history of java.pptx real bihind the name java
mushtaqsaliq9
?
Introduction to Safety, Health & Environment
Introduction to Safety, Health  & EnvironmentIntroduction to Safety, Health  & Environment
Introduction to Safety, Health & Environment
ssuserc606c7
?

Build Automation in Android

  • 1. Build Automation for Mobile or How to Deliver Quality Apps Continiously Angelo R¨¹ggeberg
  • 2. 2 Things to remember ?Publishing your App should not be painfull¡° Angelo R¨¹ggeberg ?Code Quality Matters¡° Angelo R¨¹ggeberg
  • 3. 3 Who am I? ? Mobile Development ? Android ? iOS ? Backend ? Cloud Infrastructure http://plus.google.com/+AngeloR¨¹ggeberg http://s3xy4ngyc.github.io/ s3xy4ngyc
  • 4. 4 Release Process Current Situation
  • 5. 5 Release Process Current Situation
  • 6. 6 Release Process the future Everything you have to do afterwards is git push
  • 7. 7 Release Process the future
  • 8. 8 Build Automation What will we be using jenkins Test Driven Development Git Beta Distribution Nightly Versions Gradle
  • 9. 9 Build Automation Benefits ? New Features are Live ASAP ? As Soon As Pushed ? Only Stable and Tested Builds can be Pushed ? No more unstable Releases ? Less Human Testing ? No more Sharing of Sensitive Data ? Keystores ? Logins
  • 10. 10 Build Automation Jenkins Jenkins is an award-winning application that monitors executions of repeated jobs, such as ? Building/testing software projects continuously ? Monitoring executions of externally-run jobs Get Jenkins at: http://jenkins-ci.org/
  • 11. 11 Build Automation Build Pipeline ? Sample Build Pipeline: compile lint Tests sonar monkey runner distribute
  • 12. 12 Build Automation Build Pipeline ? Distribution will only Happen if all Previous Steps Succeed ? Tests, Code Analysis, etc. can Run Parallel ? Step by Step enables Failing Fast ? Resource Hungry Jobs like Monkey Runner will be triggered only if needed
  • 13. 13 Jenkins Usefull Tipps ? Clone Workspace SCM Plugin ? Shared Workspaces may have locks ? https://wiki.jenkins-ci.org/display/JENKINS/Clone+Workspace+SCM+Plugin ? Polling Sucks ? use Git Hooks! ? Do not run on a Small Virtual Machine ? Android Emulator needs some Hardware ? Intel HAX strongly Recommended!
  • 14. 14 Jenkins Build Monitor Plugin
  • 15. 15 Jenkins Build Pipeline View Plugin
  • 17. 17 Build Automation gradle ? Best of ANT / Maven / GANT / Ivy ? Based on Groovy Scripts ? Expressive DSL ? (Flexible) Convention over Configuration ? Easy to extend ? ?Make the impossible possible, make the possible easy and make the easy elegant.¡±
  • 18. 18 gradle flavoring ? Staging, Dev and Live Packages ? On Your Test Device no Constant Uninstalling ? Adjustable Configurations without Code Changes ? Why? ? Reproduce able builds, easy setup
  • 20. 20 gradle sample Code Project Setup Flavoring ? Same Folder Structure for every Flavor ? Flavor Specific files Overwrite Files from Main ? Only Overwrite What your Flavor Needs ? Flavor Only Files Possible
  • 21. 21 gradle sample Code Example Flavor Specific Manifest ? Only Provider defined ? Everything else comes from main/AndroidManifest.xml
  • 22. 22 Build Automation git ? Branching ? Opensource ? Integrated and Extended Implementations
  • 23. 23 Git Git Workflow Git Flow Branching Model source: www.atlassian.com
  • 24. 24 Jenkins Git Flow and Jenkins Examples ? Staging ? Hook on develop Branch ? Nightly ? Time Based Build (eg once a day at 0 AM) ? builds newest feature Branch ? Live ? Only Builds release Tags ? Release Notes are Tag Message
  • 25. 25 Beta Test Distribution
  • 26. 26 Beta Test Distribution Examples ? Google Play ? Alpha / Channel ? Works on every Device that has The Playstore ? Crashlytics ? Distribution Groups & User Level ? gradle Integration ? free ? HokeyApp ? Comercial
  • 27. 27 Unit Testing WHY? Testing - Do it
  • 29. 29 Unit Testing WHY? ? Code Quality Matters! ? Insurance everything still works ? As it should be working ? Refactoring made easy ? Unittests are somehow a Functional Documentation
  • 30. 30 Unit Testing Some Tipps: ? Tests first! ? Simplest and dumbest way to implement ? Test Orientation Changes ? Test State Changes ? Lock Screen ? Incoming calls ? etc. ? Check Code Coverage
  • 31. 31 Test Frameworks Unittests ? Robolectric ? No Emulator Needed ? No Mocking Frameworks Needed ? API Level Emulation only up to 18 (currently) ? Robotium ? Silenium for Android ? User Scenarios ? Default Android Testing Framework
  • 32. 32 Test Frameworks UI Testing ? Espresso ? Ui Testing ? Double Espresso ? Espresso Gradle Port ? Ui Automator ? Android Default UI Testing Framework
  • 34. 34 Test Frameworks Device Testing Distributing instrumentation tests http://square.github.io/spoon/
  • 35. 35 Test Frameworks Device Testing
  • 36. 36 Test Frameworks Device Testing
  • 37. 37 Test Frameworks Device Testing
  • 38. 38 Build Automation Measure Code Quality ? Measure Code Quality over Time Duplicated code ? Coding standards ? Unit tests ? Complex code ? Potential bugs ? Comments ? Design and architecture
  • 39. 39 Test Frameworks Code Coverage
  • 40. 40 Test Frameworks Code Coverage
  • 41. 41 Build Automation Static Code Analysis
  • 42. 42 Build Automation Static Code Analysis ? Testing your Application makes your life more Stress free ? Code Quality ? Less Production Crashes ? Don¡¯t develop Stuff that should not go live ? Use Gradle Flavors!
  • 43. 43 Build Automation Final Thoughts ? Testing your Application makes your life more Stress free ? Code Quality ? Less Production Crashes ? Don¡¯t develop Stuff that should not go live ? DONE = RELEASED ? Use Gradle Flavors!
  • 44. 44 Release Process the future

Editor's Notes

  • #11: Imperative No phases Hard to read Flexbile Hard to extend No conventions (init, setup,..)
  • #12: Dynamically create execution order
  • #18: Groovy based build system based on ant
  • #23: Groovy based build system based on ant