A Great Idea
Continuous Integration (CI) is a really great idea.
For a guy like me it means that one week before a major product deadline I can leave early on Friday (as opposed to freaking out and working a 75 hour week.)
But, it doesn’t mean what it used to. Less that two years ago I remember talking about Continuous Integration as “Making sure someone doesn’t break the build.” Reading that statement makes me laugh now. What a ridiculously low bar.
Back then just having a server check out your code and compile it was something. Having it run unit tests the package your software for deployment was amazing.
Times have changed.
What I am now looking for in a Continuous Integration server it is completely different. I want it to grab the code and run Unit, Functional and Acceptance tests on it. Then I want a code coverage report for those tests. On top of that I want a report on standard code metrics that will tell me things like how “DRY” the code is.
To be considered exceptional all of these features need to be tightly integrated and status notifications about updates should be done over Twitter and with a Growl notifier.
Better yet the tests, coverage and metrics should be run pre-commit and anything less than 100% passing and 100% coverage should not be allowed in the repository.
Continuous Analysis & Integration
Really what we are talking about here is not Continuous Integration anymore, it is Continuous Analysis and Integration. Because it really doesn’t matter if the code integrates unless the code is also DRY and thoroughly tested.
My Wishlist
So here is my wish-list for a CI server to use on upcoming projects:
- Integration with GitHub including post commit hooks.
- The ability to run tests, coverage and metrics pre-commit via a gem (think like that Heroku magic for deploying).
- A project template that includes tabs for artifacts from test results, coverage reports and metrics
- Twitter integration.
- A growl notifier.
- Aware of Ruby/Rails for the collection of artifacts necessary for deployment.
- Integrated ability to run capistrano deployment scripts to stage a site if everything passes.
- Tasks run as worker process with customizable credentials and not as the Apache user! (I shouldn’t need to mention this one.)
- All of this out of the box without hours of configuration.
A Final Word or Two
The idea of convention over configuration is beautiful and should be applied to Continuous Integration.
A lot of systems can do anything but everything is hard. That is just dumb.
Good practices should be simple. Customization should be possible.
Post a comment if you have something that you think fits the bill. I think a lot of people would be really interested in hearing about it.