SlideShare a Scribd company logo
1 of 28
Download to read offline
Don’t Hate, Automate.
Lessons learned from implementing Continuous Delivery.
Matt Wilson, CTO Lab Zero

LAB ZERO INNOVATIONS, INC.
PIER 9, THE EMBARCADERO SAN FRANCISCO, CA 94111
T:415.839.6861 F:415.839.6901 INFO@LABZERO.COM HTTP://LABZERO.COM
Overview
Who we are

Our evolution toward Continuous D*

What we’ve learned along the way

Questions & Answers

LAB ZERO INNOVATIONS, INC.
Who We Are
Product development, design, and strategy team based in SF.
Early-stage entrepreneurs and startup founders: earfl.com, meez.com, gofish.com, echosign.
com, veodia.com.
Held senior product design & dev roles at Apple, Google, Yahoo, Kodak, Accenture.
Our clients are often startups and Fortune 500s.
Founded in 2008

Many of our clients hire us just to build out their Continuous D* rigs.

LAB ZERO INNOVATIONS, INC.
Our path to Continuous D*
and what we’ve seen
In the beginning there was
Just a build…
We had code and compiled it. We even had some unit tests for some areas of the code.
The official build ran nightly but we certainly weren’t using it for fast feedback.
Then we started deploying with automation. “cap production deploy” Those were some fancy
pants.
Then we started running our tests on every check in.
Then we needed to automate the validation of our app running in different environments
Then we started automating the creation of our environments. Just can’t have enough.

LAB ZERO INNOVATIONS, INC.
Necessity struck
We have to start new projects very often.
The teams we collaborate with want to see progress often.
Projects started without a clear delivery process were often slower to deliver over time.
At some point manually running our deployment scripts every time we wanted to share our work
seemed like too much hassle. </first_world_problem>
We need to know that the feature works in the QA environment.

We figured out how to get Continuous D* running on our projects in less than a day.

LAB ZERO INNOVATIONS, INC.
Our Webapp “Build”
Rspec:
Unit tests and generates code coverage reports.

Jasmine + PhantomJS:
Javascript unit testing.

Cucumber:
We write our ATDD suites in Cucumber and use Capybara to actually drive browsers.

Brakeman:
Static security analyzer to help us find obvious security vulnerabilities.

Capistrano:
Automated deployments of RoR, PHP, Java... applications.
LAB ZERO INNOVATIONS, INC.
Our Mobile “Build”
Xcodebuild, Ant+javac:
iOS and Android command line tools.

OCUnit, JUnit:
iOS and Android unit testing frameworks.

Cucumber:
Using Calabash to actually drive the native devices and emulators.

TestFlight:
Deploy every passing build to TestFlight for easy distribution to team devices.

LAB ZERO INNOVATIONS, INC.
The story starts at your laptop and ends in production.

LAB ZERO INNOVATIONS, INC.
TDD
the first “d” is for “driven”
Build Failed
“When the light is green, the trap is clean.” --Ghostbusters
It’s hard to keep the light green or meaningful if tests
are written afterwards.
Build your culture of automation awareness.
There is a correlation between writing tests and running them. Those that write them tend to run
them more often.
Developers and QA both need to run tests before committing.
If developers aren’t running the tests because they take too long, it’s worth the investment to
speed them up.

CD can fall apart quickly if the team doesn’t react early to failed builds.

LAB ZERO INNOVATIONS, INC.
Speed will matter
when you’re doing it right
How long does it take to deliver a feature to QA?

LAB ZERO INNOVATIONS, INC.
Ouch, my tests!
We want to run as many tests as we can but once we’ve invested in a fair amount of browser
and emulator testing they get really slow.
When they get slow we become reluctant to run them.
Tests that don’t run, can’t find bugs.
The longer you wait to run them all, the less likely they are to still pass.
Tests that are broken and remain unfixed become dead weight.
Releasing under-tested products often means we’re asking too much of our QA teams and
usually won’t find bugs until they are in production.

LAB ZERO INNOVATIONS, INC.
Usual suspects for slowness in the pipe
Heavy use of fixtures and db cleaning (factory-girl and database-cleaner)
Consider using mocks/stubs instead of db’s when possible.
Android emulator
Get a real device and plug it into your CI server.
Assets compiled on each server at deploy time
Pre-compile your static assets on the build server and deploy archives instead.

LAB ZERO INNOVATIONS, INC.
Parallulala, parallaluh, parallelize them
Selenium tests are just too slow to not do this
Remote browser tests will need you to run multiple tests at once. Especially when you start
considering running your tests in more than one browser/OS combo.
To do this well you should lean on the PaaSs out there like
Solano CI (beaucoup parallelization-fu), Sauce Labs (browsers and mobile emulators, can be
used from Solano), Travis CI, etc...
Unit tests will need it too
If you’re doing TDD, you likely already have this problem.

LAB ZERO INNOVATIONS, INC.
Continuous D* wants to use your test automation
across many environments
You’ll need a few environments to pull this off.
CI Server
Run tests here first to find anything that should prevent us from deploying the app. Unit tests,
static analysis,
DevInteg
First deployed spot for the app, the environment will be volatile and will serve little use other than
for CI. May also serve as QA server if the numbers of commits are low.
QA1, 2, 3..
You may need one of these for each product team.
Staging
Runs in production and is often used as a place to validate the app in production before going
live.
Production
Live.
LAB ZERO INNOVATIONS, INC.
We want to get the features out, but they have to be
verified in QA and Staging before we go live.

LAB ZERO INNOVATIONS, INC.
Co-own yer ATDD

with QA
Force multiplier
Share the same ATDD code
Devs and QA should collaborate on their functional testing investment. Many organizations
separate these groups activities which leads to redundant investments.
Devs need to lead in the spirit of TDD
Relying only on QA for functional automation causes flapping red->red->green->red->green
builds.
It works better when you work together
Devs can do the heavy lifting on writing reusable steps and tests. QA can add more cases if
they see fit. Devs should expect to train and support QA on the tools.
Allow QA to audit
With our QA hats on, let’s have an open conversation about what should be tested and what is
missing. This is how we can focus our beams to make the light brighter.

LAB ZERO INNOVATIONS, INC.
Running tests

just one thing your CI server can do
Robots, ACL’s and users, what could go wrong?
Empower folks with a magic button
There are likely things that your team is always asking someone else to do for them. De-spof it
by making a job that folks can click whenever needed, even from their phones. Zomg seriously.
Database Refreshes
Nearly every webapp project needs to be able to reset/refresh the dev/qa/staging databases
easily.
Production deploy jobs
This is your parent’s liquor cabinet: make sure the kids don’t get into it, but make it easy to open
when needed.

LAB ZERO INNOVATIONS, INC.
Thank You!
Questions?

matt@labzero.com
twitter/aim/yim/skype: w1150n

LAB ZERO INNOVATIONS, INC.
PIER 9, THE EMBARCADERO SAN FRANCISCO, CA 94111
T:415.839.6861 F:415.839.6901 INFO@LABZERO.COM WWW.LABZERO.COM

More Related Content

What's hot

Agile Testing at eBay
Agile Testing at eBayAgile Testing at eBay
Agile Testing at eBay
Dominik Dary
 

What's hot (20)

Losing Sight of DevOps in an Automation Forest - devopsdays Atlanta 2013
Losing Sight of DevOps in an Automation Forest - devopsdays Atlanta 2013Losing Sight of DevOps in an Automation Forest - devopsdays Atlanta 2013
Losing Sight of DevOps in an Automation Forest - devopsdays Atlanta 2013
 
What to Do—Develop Your Own Automation or Use Crowdsourced Testing?
What to Do—Develop Your Own Automation or Use Crowdsourced Testing?What to Do—Develop Your Own Automation or Use Crowdsourced Testing?
What to Do—Develop Your Own Automation or Use Crowdsourced Testing?
 
Sauce Labs+Applitools - Automated Visual Testing in the Cloud
Sauce Labs+Applitools - Automated Visual Testing in the CloudSauce Labs+Applitools - Automated Visual Testing in the Cloud
Sauce Labs+Applitools - Automated Visual Testing in the Cloud
 
Un Viaggio Verso DevOps
Un Viaggio Verso DevOpsUn Viaggio Verso DevOps
Un Viaggio Verso DevOps
 
DevOps – the future of Agile – why, what, how? Agile Israel 2014
DevOps – the future of Agile – why, what, how? Agile Israel 2014DevOps – the future of Agile – why, what, how? Agile Israel 2014
DevOps – the future of Agile – why, what, how? Agile Israel 2014
 
Automated Exploratory Testing
Automated Exploratory TestingAutomated Exploratory Testing
Automated Exploratory Testing
 
A DevOps Primer: Whole Team Approaches for Better Software Quality
A DevOps Primer: Whole Team Approaches for Better Software QualityA DevOps Primer: Whole Team Approaches for Better Software Quality
A DevOps Primer: Whole Team Approaches for Better Software Quality
 
Achieving Continuous Delivery with Puppet
Achieving Continuous Delivery with PuppetAchieving Continuous Delivery with Puppet
Achieving Continuous Delivery with Puppet
 
Lemi Orhan Ergin - Code Your Agility: Tips for Boosting Technical Agility in ...
Lemi Orhan Ergin - Code Your Agility: Tips for Boosting Technical Agility in ...Lemi Orhan Ergin - Code Your Agility: Tips for Boosting Technical Agility in ...
Lemi Orhan Ergin - Code Your Agility: Tips for Boosting Technical Agility in ...
 
DevOps beyond the Tools
DevOps beyond the ToolsDevOps beyond the Tools
DevOps beyond the Tools
 
The Phoenix Project DevOps Simulation - Paul Wilkinson
The Phoenix Project DevOps Simulation - Paul WilkinsonThe Phoenix Project DevOps Simulation - Paul Wilkinson
The Phoenix Project DevOps Simulation - Paul Wilkinson
 
The Test Pyramid
The Test PyramidThe Test Pyramid
The Test Pyramid
 
Enterprise Devops Presentation @ Magentys Seminar London May 15 2014
Enterprise Devops Presentation @ Magentys Seminar London May 15 2014Enterprise Devops Presentation @ Magentys Seminar London May 15 2014
Enterprise Devops Presentation @ Magentys Seminar London May 15 2014
 
Best Practices in Mobile CI (webinar)
Best Practices in Mobile CI (webinar)Best Practices in Mobile CI (webinar)
Best Practices in Mobile CI (webinar)
 
Agile Testing at eBay
Agile Testing at eBayAgile Testing at eBay
Agile Testing at eBay
 
Live Panel: Appium Core Committers Answer Your Questions
Live Panel: Appium Core Committers Answer Your Questions		Live Panel: Appium Core Committers Answer Your Questions
Live Panel: Appium Core Committers Answer Your Questions
 
Devops, the future is here, it's just not evenly distributed yet.
Devops, the future is here, it's just not evenly distributed yet.Devops, the future is here, it's just not evenly distributed yet.
Devops, the future is here, it's just not evenly distributed yet.
 
Agile Tools for Mobile
Agile Tools for MobileAgile Tools for Mobile
Agile Tools for Mobile
 
[Srijan Wednesday Webinars] Building a High Performance QA Team
[Srijan Wednesday Webinars] Building a High Performance QA Team[Srijan Wednesday Webinars] Building a High Performance QA Team
[Srijan Wednesday Webinars] Building a High Performance QA Team
 
Surviving SOA - delivering (somewhat) continuously on a hostile planet
Surviving SOA - delivering (somewhat) continuously on a hostile planetSurviving SOA - delivering (somewhat) continuously on a hostile planet
Surviving SOA - delivering (somewhat) continuously on a hostile planet
 

Similar to Don't hate, automate. lessons learned from implementing continuous delivery

Building a DevOps Team that isn't Evil
Building a DevOps Team that isn't EvilBuilding a DevOps Team that isn't Evil
Building a DevOps Team that isn't Evil
IBM UrbanCode Products
 
Gozengo sauce presentation
Gozengo sauce presentationGozengo sauce presentation
Gozengo sauce presentation
Daniel Straus
 

Similar to Don't hate, automate. lessons learned from implementing continuous delivery (20)

30 days or less: New Features to Production
30 days or less: New Features to Production30 days or less: New Features to Production
30 days or less: New Features to Production
 
DevOps in the Amazon Warehouse - Shawn Gandhi
DevOps in the Amazon Warehouse - Shawn GandhiDevOps in the Amazon Warehouse - Shawn Gandhi
DevOps in the Amazon Warehouse - Shawn Gandhi
 
Agile & DevOps - It's all about project success
Agile & DevOps - It's all about project successAgile & DevOps - It's all about project success
Agile & DevOps - It's all about project success
 
The unintended benefits of Chef
The unintended benefits of ChefThe unintended benefits of Chef
The unintended benefits of Chef
 
Continuous Load Testing with CloudTest and Jenkins
Continuous Load Testing with CloudTest and JenkinsContinuous Load Testing with CloudTest and Jenkins
Continuous Load Testing with CloudTest and Jenkins
 
Scale security for a dollar or less
Scale security for a dollar or lessScale security for a dollar or less
Scale security for a dollar or less
 
DevOps
DevOpsDevOps
DevOps
 
DevOps: The New Face Of Application Development - Global Azure Bootcamp
DevOps: The New Face Of Application Development - Global Azure BootcampDevOps: The New Face Of Application Development - Global Azure Bootcamp
DevOps: The New Face Of Application Development - Global Azure Bootcamp
 
DevOps in Practice: When does "Practice" Become "Doing"?
DevOps in Practice: When does "Practice" Become "Doing"?DevOps in Practice: When does "Practice" Become "Doing"?
DevOps in Practice: When does "Practice" Become "Doing"?
 
Principles and Practices in Continuous Deployment at Etsy
Principles and Practices in Continuous Deployment at EtsyPrinciples and Practices in Continuous Deployment at Etsy
Principles and Practices in Continuous Deployment at Etsy
 
Strengthen and Scale Security for a dollar or less
Strengthen and Scale Security for a dollar or lessStrengthen and Scale Security for a dollar or less
Strengthen and Scale Security for a dollar or less
 
Confoo-Montreal-2016: Controlling Your Environments using Infrastructure as Code
Confoo-Montreal-2016: Controlling Your Environments using Infrastructure as CodeConfoo-Montreal-2016: Controlling Your Environments using Infrastructure as Code
Confoo-Montreal-2016: Controlling Your Environments using Infrastructure as Code
 
Continuous deployment
Continuous deploymentContinuous deployment
Continuous deployment
 
Continuous Delivery for Agile Teams
Continuous Delivery for Agile TeamsContinuous Delivery for Agile Teams
Continuous Delivery for Agile Teams
 
Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...
Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...
Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...
 
DevOps - Boldly Go for Distro
DevOps - Boldly Go for DistroDevOps - Boldly Go for Distro
DevOps - Boldly Go for Distro
 
Harman deepak v - agile on steriod - dev ops led transformation
Harman  deepak v - agile on steriod - dev ops led transformationHarman  deepak v - agile on steriod - dev ops led transformation
Harman deepak v - agile on steriod - dev ops led transformation
 
Continuous Load Testing with CloudTest and Jenkins
Continuous Load Testing with CloudTest and JenkinsContinuous Load Testing with CloudTest and Jenkins
Continuous Load Testing with CloudTest and Jenkins
 
Building a DevOps Team that isn't Evil
Building a DevOps Team that isn't EvilBuilding a DevOps Team that isn't Evil
Building a DevOps Team that isn't Evil
 
Gozengo sauce presentation
Gozengo sauce presentationGozengo sauce presentation
Gozengo sauce presentation
 

More from Solano Labs

More from Solano Labs (8)

Constant Contact SF's Road to CD
Constant Contact SF's Road to CDConstant Contact SF's Road to CD
Constant Contact SF's Road to CD
 
Testing sad-paths
Testing sad-pathsTesting sad-paths
Testing sad-paths
 
Why Software Test Performance Matters
Why Software Test Performance MattersWhy Software Test Performance Matters
Why Software Test Performance Matters
 
The 10 Commandments of Release Engineering
The 10 Commandments of Release EngineeringThe 10 Commandments of Release Engineering
The 10 Commandments of Release Engineering
 
Boston MeetUp 10.10
Boston MeetUp 10.10Boston MeetUp 10.10
Boston MeetUp 10.10
 
NYC MeetUp 10.9
NYC MeetUp 10.9NYC MeetUp 10.9
NYC MeetUp 10.9
 
Object-Oriented BDD w/ Cucumber by Matt van Horn
Object-Oriented BDD w/ Cucumber by Matt van HornObject-Oriented BDD w/ Cucumber by Matt van Horn
Object-Oriented BDD w/ Cucumber by Matt van Horn
 
Automated testing san francisco oct 2013
Automated testing san francisco oct 2013Automated testing san francisco oct 2013
Automated testing san francisco oct 2013
 

Recently uploaded

Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 

Recently uploaded (20)

Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 

Don't hate, automate. lessons learned from implementing continuous delivery

  • 1. Don’t Hate, Automate. Lessons learned from implementing Continuous Delivery. Matt Wilson, CTO Lab Zero LAB ZERO INNOVATIONS, INC. PIER 9, THE EMBARCADERO SAN FRANCISCO, CA 94111 T:415.839.6861 F:415.839.6901 INFO@LABZERO.COM HTTP://LABZERO.COM
  • 2. Overview Who we are Our evolution toward Continuous D* What we’ve learned along the way Questions & Answers LAB ZERO INNOVATIONS, INC.
  • 3. Who We Are Product development, design, and strategy team based in SF. Early-stage entrepreneurs and startup founders: earfl.com, meez.com, gofish.com, echosign. com, veodia.com. Held senior product design & dev roles at Apple, Google, Yahoo, Kodak, Accenture. Our clients are often startups and Fortune 500s. Founded in 2008 Many of our clients hire us just to build out their Continuous D* rigs. LAB ZERO INNOVATIONS, INC.
  • 4. Our path to Continuous D* and what we’ve seen
  • 5. In the beginning there was Just a build… We had code and compiled it. We even had some unit tests for some areas of the code. The official build ran nightly but we certainly weren’t using it for fast feedback. Then we started deploying with automation. “cap production deploy” Those were some fancy pants. Then we started running our tests on every check in. Then we needed to automate the validation of our app running in different environments Then we started automating the creation of our environments. Just can’t have enough. LAB ZERO INNOVATIONS, INC.
  • 6. Necessity struck We have to start new projects very often. The teams we collaborate with want to see progress often. Projects started without a clear delivery process were often slower to deliver over time. At some point manually running our deployment scripts every time we wanted to share our work seemed like too much hassle. </first_world_problem> We need to know that the feature works in the QA environment. We figured out how to get Continuous D* running on our projects in less than a day. LAB ZERO INNOVATIONS, INC.
  • 7. Our Webapp “Build” Rspec: Unit tests and generates code coverage reports. Jasmine + PhantomJS: Javascript unit testing. Cucumber: We write our ATDD suites in Cucumber and use Capybara to actually drive browsers. Brakeman: Static security analyzer to help us find obvious security vulnerabilities. Capistrano: Automated deployments of RoR, PHP, Java... applications. LAB ZERO INNOVATIONS, INC.
  • 8. Our Mobile “Build” Xcodebuild, Ant+javac: iOS and Android command line tools. OCUnit, JUnit: iOS and Android unit testing frameworks. Cucumber: Using Calabash to actually drive the native devices and emulators. TestFlight: Deploy every passing build to TestFlight for easy distribution to team devices. LAB ZERO INNOVATIONS, INC.
  • 9. The story starts at your laptop and ends in production. LAB ZERO INNOVATIONS, INC.
  • 10. TDD the first “d” is for “driven”
  • 12. “When the light is green, the trap is clean.” --Ghostbusters
  • 13. It’s hard to keep the light green or meaningful if tests are written afterwards. Build your culture of automation awareness. There is a correlation between writing tests and running them. Those that write them tend to run them more often. Developers and QA both need to run tests before committing. If developers aren’t running the tests because they take too long, it’s worth the investment to speed them up. CD can fall apart quickly if the team doesn’t react early to failed builds. LAB ZERO INNOVATIONS, INC.
  • 14. Speed will matter when you’re doing it right
  • 15. How long does it take to deliver a feature to QA? LAB ZERO INNOVATIONS, INC.
  • 16. Ouch, my tests! We want to run as many tests as we can but once we’ve invested in a fair amount of browser and emulator testing they get really slow. When they get slow we become reluctant to run them. Tests that don’t run, can’t find bugs. The longer you wait to run them all, the less likely they are to still pass. Tests that are broken and remain unfixed become dead weight. Releasing under-tested products often means we’re asking too much of our QA teams and usually won’t find bugs until they are in production. LAB ZERO INNOVATIONS, INC.
  • 17. Usual suspects for slowness in the pipe Heavy use of fixtures and db cleaning (factory-girl and database-cleaner) Consider using mocks/stubs instead of db’s when possible. Android emulator Get a real device and plug it into your CI server. Assets compiled on each server at deploy time Pre-compile your static assets on the build server and deploy archives instead. LAB ZERO INNOVATIONS, INC.
  • 18. Parallulala, parallaluh, parallelize them Selenium tests are just too slow to not do this Remote browser tests will need you to run multiple tests at once. Especially when you start considering running your tests in more than one browser/OS combo. To do this well you should lean on the PaaSs out there like Solano CI (beaucoup parallelization-fu), Sauce Labs (browsers and mobile emulators, can be used from Solano), Travis CI, etc... Unit tests will need it too If you’re doing TDD, you likely already have this problem. LAB ZERO INNOVATIONS, INC.
  • 19. Continuous D* wants to use your test automation across many environments
  • 20.
  • 21.
  • 22. You’ll need a few environments to pull this off. CI Server Run tests here first to find anything that should prevent us from deploying the app. Unit tests, static analysis, DevInteg First deployed spot for the app, the environment will be volatile and will serve little use other than for CI. May also serve as QA server if the numbers of commits are low. QA1, 2, 3.. You may need one of these for each product team. Staging Runs in production and is often used as a place to validate the app in production before going live. Production Live. LAB ZERO INNOVATIONS, INC.
  • 23. We want to get the features out, but they have to be verified in QA and Staging before we go live. LAB ZERO INNOVATIONS, INC.
  • 25. Force multiplier Share the same ATDD code Devs and QA should collaborate on their functional testing investment. Many organizations separate these groups activities which leads to redundant investments. Devs need to lead in the spirit of TDD Relying only on QA for functional automation causes flapping red->red->green->red->green builds. It works better when you work together Devs can do the heavy lifting on writing reusable steps and tests. QA can add more cases if they see fit. Devs should expect to train and support QA on the tools. Allow QA to audit With our QA hats on, let’s have an open conversation about what should be tested and what is missing. This is how we can focus our beams to make the light brighter. LAB ZERO INNOVATIONS, INC.
  • 26. Running tests just one thing your CI server can do
  • 27. Robots, ACL’s and users, what could go wrong? Empower folks with a magic button There are likely things that your team is always asking someone else to do for them. De-spof it by making a job that folks can click whenever needed, even from their phones. Zomg seriously. Database Refreshes Nearly every webapp project needs to be able to reset/refresh the dev/qa/staging databases easily. Production deploy jobs This is your parent’s liquor cabinet: make sure the kids don’t get into it, but make it easy to open when needed. LAB ZERO INNOVATIONS, INC.
  • 28. Thank You! Questions? matt@labzero.com twitter/aim/yim/skype: w1150n LAB ZERO INNOVATIONS, INC. PIER 9, THE EMBARCADERO SAN FRANCISCO, CA 94111 T:415.839.6861 F:415.839.6901 INFO@LABZERO.COM WWW.LABZERO.COM