Here is a list of 15 plus continuous integration tips or do’s and don’ts for your software. If you have more tips, please add them to the comment section. I will pick it up from there and add it to this list.
Maintain single source code repository
Commit code frequently. Ideally have everyone in your team commit their code everyday.
Run all test cases / test suites locally before committing your code to the repository.
Never check-in a broken build – if you found broken test cases, fix those before committing the code.
If you checked in a code that broke the build, fix it. Take responsibility on the build that you broke.
Don’t comment out failing test cases – fix them.
Automate the build process using tools like Ant or Maven.
Automate the unit tests so that on every build whole set of test cases run.
Make a clear separation of Unit Tests and Integratio Tests
Configure the build so that every commit to the repository triggers a build.
Keep the builds fast – fail the build if it runs for too long and optimize the build process.
Replicate production environment as closely as possible on your test environments.
Make the results of your test cases visible to everyone in your team.
Send an email to the team for every build – both for success and failure.
Auotmate your deployment process – ideally set up a trigger to run a deployment once the build is complete.
Run static code analysis tools like checkstyle on your every build and fail the build in case of violations.
As we know, the waterfall model of software engineering is getting obsolete day by day as more and more companies are choosing to go for the agile model of software development where they have seen lots of solid benefits by trying the agile and experimenting with variations of it to fit their own need. Agile is not rigid set of rules, although there are guiding principles.
So what are the benefits of using the iterative development also called sprints in Agile? Here are a few that I can think of.
Iterative development in agile has a continuous focus on improving the processes.
Iterative development pays attention to the quality of work, learning from what went bad and what things went good in prior iterations.
Iterative development can help align or modify the priorities based on the outcome of the previous iteration deliveries.
Business priorities and the business values can change all the time. Iterative development helps to adjust those values and priorities.
With iterative development, the estimates get better as we grow. This estimate will be close to reality than the waterfall model of development where the estimations are done at the beginning of the project, which might not hold true as the project progresses.
In the iterative development, there is opportunity to build the highest risk items first.
Iterative development allows the testing to occur early and often.
Iterative development allows to deliver the product early and deliver often.
Risk discover, risk analysis and risk mitigation can occur earlier.
Allows us to change the software even in the late cycle of development.
Because of the splitting of the task, the complexity in the iterations are manageable.
Iterative development helps produce early parrtial product which in turn can obtain early feedback and changes.
With the continuous delivery and continous feedback, the final product becomes more closer to what user needs.
Iterative development enforces better communication and engagement.
Time boxed iterations give an idea of when to expect the delivery.