6. DevOps and Continuous
Integration
A Portmanteau of Development and Operations
Stresses Communication, Collaboration and Integration
Aims To Enable Rapid Applications Development and
Deployment
Standardizes Development Environments
Thursday, July 4, 13
7. DevOps and
Continuous Integration
“DevOps integration targets product delivery, quality
testing, feature development and maintenance releases
in order to improve reliability and security and faster
development and development cycles.”
http://en.wikipedia.org/wiki/DevOps
Thursday, July 4, 13
8. DevOps and Continuous Integration
Merges all developer workspaces with shared mainline
Originated in XP to facilitate Test-Driven Development
Establishes Quality Control throughout development
Increases Rate of Delivery through small efforts applied
frequently
Continuous Integration
Thursday, July 4, 13
9. DevOps and Continuous Integration
+ Code Coverage measures the degree to which
the source code of a program has been tested.
Code Coverage
+ Typically an automated Unit Test for any POJO
class and/or method is the manner through
which code coverage is measured.
+ Typically an automated Unit Test for any POJO
class and/or method is the manner through
which code coverage is measured.
Thursday, July 4, 13
10. DevOps and Continuous Integration
+ Popular automated build tools such as
Hudson and Jenkins are used to run automated
tests through plugins such as J-Unit or TestNG
Code Coverage
+ Sonar, now SonarQube is a popular open
source tool for producing code coverage reports
+ Atlassian Bamboo is a tool for scripting
automated builds and producing related reports.
Thursday, July 4, 13
11. DevOps and Continuous Integration
+ Technical Debt is deficiencies in software
development practice that results in rework or
revisiting code that could otherwise have been
made available for release.
+ Code that has such deficiencies should fail to
meet the team’s “Definition of Done” because all
regressions tests have not been successful.
Technical Debt
Thursday, July 4, 13
12. DevOps and Continuous Integration
TDD is related to the “test first” programming
concepts of XP.
1) Write a failing test.
2) Write the code to allow the test to pass.
3) Refactor the code without introducing defects.
Test-Driven Development
Thursday, July 4, 13
13. DevOps and Continuous Integration
BDD is an automated Acceptance Test Driven
Development (ATDD) technique also know as
“Specification by Example”
Behavior-Driven Development
Thursday, July 4, 13
14. DevOps and Continuous Integration
BDD is an automated Acceptance Test Driven
Development (ATDD) technique also know as
“Specification by Example”
Behavior-Driven Development
BDD is performed by capturing requirements as
scenarios and then automating the scenarios as
a test.
Thursday, July 4, 13
15. DevOps and Continuous Integration
Behavior-Driven Development
Story: Returns go to stock
In order to keep track of stock
As a store owner
I want to add items back to stock when they're returned
Scenario 1: Refunded items should be returned to stock
Given a customer previously bought a black sweater from me
And I currently have three black sweaters left in stock
When he returns the sweater for a refund
Then I should have four black sweaters in stock
Scenario 2: Replaced items should be returned to stock
Given that a customer buys a blue garment
And I have two blue garments in stock
And three black garments in stock.
When he returns the garment for a replacement in black,
Then I should have three blue garments in stock
And two black garments in stock
Thursday, July 4, 13
16. DevOps and Continuous Integration
Popular tools for implementing BDD include
JBehave and Cucumber JVM
Behavior-Driven Development
Sonar reports may be used to capture and
report BDD test results as part of the daily build
done to facilitate Continuous Integration.
Thursday, July 4, 13