Hacker News new | ask | show | jobs
by PaulHoule 877 days ago
My take is that one way to make sure that value > cost for tests is to use tests as a form of documentation or to support documentation.

One of the best applications for "literate programming" is to put all the code snippets in the documentation into unit tests. If you don't do that it seems impossible that you could write a book like The C Programming Language and have the examples really work.