5 years of Test Driven Development, Visualized

Here’s a 15 minute video covering nearly 5 years of active Mir development in C++.

We (the original Mir team), started the project by reading “Growing Object-Oriented Software, Guided by Tests” by Steve Freeman and Nat Price (book site).  We followed the philosophy of test-driven development
closely after that, really throughout the whole project.

This is a video generated by the program ‘gource’. What you see is every file or directory is a node. Little avatars, one for every contributor zoom around the files and zap them when a change is made. If you watch closely, some contributors will fixate on a few files for a bit (bug hunting, maybe?) and sometimes the avatars zap a lot of files during close succession, during feature additions and refactoring.

A few things to point out about TDD in the visualization. At the end, the 3 biggest branches are headers, source code and tests. The size of those components remained roughly the same throughout the whole project, which shows that we were adding a test, and then fleshing out the source code (and supporting headers from there). When an avatar zaps a lot of files at once, there’s always a corresponding zapping of the tests tree and the source tree. Write the test first! Very cool to see how things come together with TDD on a large, sustained, and high quality code base.

 

This entry was posted in Coding. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *