N
Noah Roberts
James said:Define "documenting unit tests". A unit test doesn't document
anything. And passing a unit test doesn't prove readability.
Unit tests are an essential part of the development process (and
given the possible standards cited by the original poster, and
the environment from which they come, I'm rather certain he's
aware of this). But you still need guidelines for such basic
things as naming conventions, indentation, file organization...
Another agile development paradigm. The unit tests, since they cover
the entire API, serve as documentation for said API. If I want to know
how a particular class is meant to be used, I can look at the unit
tests. Of course, the unit tests often need some sort of documentation
of their own.
I don't totally disagree with the reasoning. Quite often the best way
to learn how to use something is to see it used. That's what the unit
tests do. I don't agree though that it works in all cases or for all
people. Thus we do both unit tests AND doxygen AND uml AND comments
where something is weird.