http://qs321.pair.com?node_id=728666


in reply to Code Maintainability

Want to write maintainable code? Then learn the unit testing frameworks and use them.

The act of writing tests against your code can flush out a lot of nonsense. The act of writing tests first, before you write production code, can flush a lot of nonsense out of your design.

Having good tests improves the chances that whoever picks up the code next won't break something and not realized it. That's maintainability.

Beautiful code but no tests? You're only halfway there.