Importance of Continuous Integration

Continuous Integration (CI) is a practice that requires developers to integrate their code into a shared repository frequently at least daily, which leads to multiple integrations per day by different developers. Each commit made by the developers are then verified by an automated build, which detects problems early and communicate the team members.

The basic concept of CI is a system that builds the code and runs automated tests every-time when someone makes a commit to the version control system (code repository). These tests would include unit and functional tests, or even behavior driven tests.

It has the advantage of highlighting when code changes break the system as early as possible. It not only detect breaks in the code, it highlights who caused the break. This psychological effect is very effective in encouraging good testing prior to check in!

Sometimes developers think that it is a small change and it will not break the Application and they will ignore to run tests. BUT there are chances of system going down and then they will realize. ONLY automated tests can only show true results (PASS/FAIL) when we run them continuously and for each and every change (may be a small change).

The main advantage of running all tests immediately for every change is that you will come to know right away if something broke. AND It is always a good way to catch bugs more quickly and efficiently is to include automated tests in the build process.

This is exactly how continuous integration looks like : -

continuous integration

Example: Consider you are working on a 2 week sprint.
On Day 2 of the sprint, one of your team member changes something that breaks a test. If you don’t continuously run all of the tests, there is a chance that nobody identifies the problem and Other team members will be working with same, and at the end of the sprint, you run the whole test suite. Now the test fails.

Finding the commit that broke the tests will become hard as has been 2 weeks since the breaking change was committed and has a lot of commits since then.

The below are the list of Continuous Integration tools which are available in Market:

1. Jenkins CI is the leading open source continuous integration server, built with Java and it provides over 400 plug-ins to support building and testing your software projects

2. Bamboo Bamboo is a continuous integration and delivery tool that ties automated builds, tests and releases together in a single workflow.

3. TeamCity With TeamCity you can build, check and run automated tests on the server even before committing your changes — keeping your code base clean at all times.

4. CruiseControl is a free and open source project built with Java and hosted on Sourceforge.

5. Travis CI Travis is a CI solution initially designed for Rails apps, but now it supports more languages including PHP, JavaScript, C/C++, Objective-C, Python, Haskel, etc.

6. Buildbot is a job scheduling system, it queues jobs, executes the jobs when the required resources are available, and reports the results.

Comments

Please guide us through a tutorial on the integration between GIT/SVN with jenkins

Add new comment

Image CAPTCHA