Episode 2: Test areas in Continuous Delivery – Gav Patel

Continuous Delivery – Part 2 – Testing

In the second part of our video series on Continuous Delivery, we look at the testing phase.

Testing plays a crucial and integral part of the continuous delivery process.

Testing is a process where we validate the developed product against functional and non functional requirements. In this phase we can find out if the product actually works as per the design and fulfils the user stories, while not having a detrimental impact on existing features.

The testing phase in a continuous delivery process exists to provide a constant feedback loop which helps determine if further changes are needed. The faster and earlier the feedback the smoother the releases.

But true to our faster, safer, better mantra, we can only be better if we are faster and we can only be faster if we are safer.

While there are many areas of testing, three main ones for Continuous Delivery are:

Unit testing – Where the developers code in Test Driven Development (TDD), create the failing test first and then the code around it until the test passes. These tests are fast to create, allow for better coding practices and are very fast to execute.

Integration testing – now we bring together pieces of code and functionality, such as a database along with some code for logic.   While it may not be pretty we can validate inputs and outputs.

Functional testing – finally we bring all the parts together and test end to end functionality such as front end, logic and database. Here we could use something like webdriver to mimic user behaviour.

The above are some of the main traditional testing areas but we need to do things slightly differently in Continuous Delivery. We need a constant feedback loop, so therefore tests running all the time, on every checkin. As some of the tests can take a considerable amount of time to run, especially the functional tests such as the web driver ones, we need to choose happy paths, or use a parallel grid version of selenium to speedup testing.

Testing within agile and Continuous Delivery is a team exercise, from developers ensuring there are unit tests, to testers carrying out functional tests and product owners doing UAT. It’s a team effort and forms an essential essence of “done”.

In order to release faster there is the downside, tests have to be kept up to date, testing time can be extensive, and environments will need to be standardised to ensure all our efforts are never wasted.

Final thoughts

Continuous delivery is about faster time to market, while controlling risk. In order to do this we need to be safe, and to be safe we need to test early, test often and automate as much as we can.

Without proper testing Continuous Delivery is not possible. 

Part 1 The introduction to the series is available here

Related Posts

Leave a comment