InfoQ

InfoQ

News

My Bookmarks

Login or Register to enable bookmarks for unlimited time.

The content has been bookmarked!

There was an error bookmarking this content! Please retry.

A Manifesto of Done

Posted by Shane Hastie on Mar 19, 2010

Sections
Process & Practices,
Architecture & Design,
Development
Topics
Programming ,
Agile ,
Software Craftsmanship

Alixx Skevington posted a Manifesto of Done as the beginning of a discussion thread, talking about the commitments team members make to each other about the quality of their work and clearly expressing their commitment to delivering business value through the code.

His list of Done criteria is:
  • I will make sure that my code is usable. My code is for use and interaction with other people, and everything I write must make this a pleasurable experience, and reduce workload not increase it.
  • I will make the code I write confirm to the style agreed by the team. People other than myself, will be maintaining and amending my code. So while I have flexibility to design and utilise any technology to build my solution. Abiding by the standard while I write this code will allow others to maintain my code.
  • I agree to keep my methods to a reasonable size. Large methods are difficult to navigate, and make difficult to debug. As far as possible I will keep my methods to a reasonable size to alleviate this complexity.
  • I will comment all code. Whether I am creating new code or altering existing code; I will make short but succinct comments to explain what I have done. So that others reading the code after me understand what I have done and what the code is trying to achieve.
  • I agree to unit test my code. I agree to make these tests re-usable and not brittle. I will make the test explain what it is testing and why. So not only will others be able to run my tests when they refactor or fix bugs; they will also be able to see what my code was trying to achieve.
  • I agree to maintain the unit tests for existing code. When I alter or add new features to existing code, I will make sure that all the tests pass and that there are new ones for any new feature.
  • I agree to try to get my code coverage to at least 80%. By checking my code coverage I will make sure that everything I write has value. That there are no surprises’ in my code that could cause problems later. I will endeavour to get this figure higher.
  • I agree to check my code integrates correctly. When I have finished writing my code I will work with the other developers working on my feature to make sure that my code works well with all the other code and that it delivers the requested functionality.

The post generated a number of comments on LinkedIn with suggestions for additional items to be added to the list, such as: 

 

I would add "I will re-run unit tests before check-in". The reason I suggest this is seemingly unrelated code in one place can break tests and/or code in another place. This happened several times at my last job.   (David Kramer)
Re: the bits about unit tests: in fact I would change that to "I will write the unit tests before I write the code", because I'm a big believer in TDD. Another thing to say about tests: they are production code, treat them like it. (Scott Ames)
Scott Mcphee disagrees with the code comment item:
as for the line about commenting code, I can't say that I disagree more. Comments frequently lie, or just captain obvious stuff (eg. /* set x to y */ x=y;), and always just add extra baggage that has to be maintained in line with the actual code. Good clearly written, clearly designed code doesn't need "succinct comments to explain what I have done" - it's obvious from the code what it does, and the SCM commit comment and version diffs should illuminate *why* it was done. And if it doesn't refactor until it does.  API documentation is a different beast, but this is usually aimed at users of the public methods, not readers of the code files, and it forms part of the released artifacts.
Jay Packlick added a point he considers the most crucial:
The most important definition of done is implied but merits explicit attention and I'd put it at the top of the list:  * "All Acceptance Criteria defining 'done' for a feature are expressed as tests and pass."   

 
What additions or changes would you make to this list?

Shane Hastie is an agile coach, trainer and consultant working for Software Education in Australia & New Zealand

  • This article is part of a featured topic series on Agile
Too specific by Machiel Groeneveld Posted
Re: Too specific by Assaf Stone Posted
Insufficient by Charlie Hammell Posted
  1. Back to top

    Too specific

    by Machiel Groeneveld

    If it's a manifesto, it should be general enough to apply to many situations. I really like the "the use of my code a pleasurable experience" because from that many good things will follow.

    I would not be so strict on a few other things. Commenting every method and every change? That's sure to make your code unreadable. The code should represent the current state clearly, not convey its history. Furthermore, code should itself be readable, good naming and good practices (such as not returning null) diminish the need for comments.

    The code coverage of 80% is arbitrary and should only be attained in situations where it adds value. I'd rather have 60% coverage with good unit tests for the tricky parts than 80% coverage with unit tests of the smoke-test kind.

  2. Back to top

    Re: Too specific

    by Assaf Stone

    How about, instead of "I will comment every change of my code", say "my code will read as if it were documentation, and everything it does will be self evident?

  3. Back to top

    Insufficient

    by Charlie Hammell

    If this defines done, then we still only have checked-in, auto-tested code. It has not been auto-deployed to QA, it has not been approved by QA, it has not been approved by the Product Owner, and it certainly has not been staged for production. All of these steps are expensive and expose a multitude of problems that leave developers blissfully ignorant of how un-ready their solutions are for business users. Definition of done: staged for production.

Educational Content

New-age Transactional Systems - Not Your Grandpa's OLTP

John Hugg discusses high volume transaction processing applications with high and low frequency profiles, and how VoltDB can be used for that purpose.

Cool Code

Kevlin Henney examines code samples to see what can be learned from them starting from the premise that one won’t write great code unless he knows how to read it.

Collaboration: At the Extremities of Extreme

Jason Ayers share the observations he made watching a team of developers collaborating in real time on the same code base, pushing XP, pair programming and continuous integration to their extremes.

Yesod Web Framework

Michael Snoyman presents Yesod, a web framework written in Haskell and containing a web server, templating, ORM, libraries (templating, gravatar, etc.).

Transactions without Transactions

Richard Kreuter and Kyle Banker on how to avoid classical RDBMS transactional systems by using compensation mechanisms, transactional messaging or transactional procedures.

Attila Szegedi on JVM and GC Performance Tuning at Twitter

Attila Szegedi talks about performance tuning Java and Scala programs at Twitter: how to approach GC problems, the importance of asynchronous I/O, when to use MySQL/Cassandra/Redis, and much more.

10 tips on how to prevent business value risk

One category of risk that project teams need to ensure they address is business value failure – delivering a product that fails to provide value for the business investor.

Interview: Software Systems Architecture: Working With Stakeholders Using Viewpoints and Perspectives

InfoQ spoke to the authors of Software Systems Architecture on a couple of new topics, the System Context viewpoint and Agile, which have been added to the second edition.