One reason for why unit testing has bothered me is that it goes against an OO principle I was thought at school, namely that every aspect of the code should be kept as private as possible.
Roy Osherove has a recent entry on this subject. Roy is an enthusiastic unit-tester, I am still in doubt :)
UPDATED 24.7.2007
Bruce Eckel's thoughts on OOP.
Showing posts with label TDD. Show all posts
Showing posts with label TDD. Show all posts
Monday, February 26, 2007
Tuesday, February 20, 2007
TDD presupposition
I am pondering the validity of the following statement:
I know that this is taken as a given in unit-test camps, but is it?
UPDATED: 1.1.2008
I found out that I am not alone in not being convinced about designing for testability. The creator of TypeMock feels that designing for testability does not comply with YAGNI.
"The theory is that testable code is better designed ... If the class is easier to test, it is a better design. The test first paradigm just forces you to use good design. It makes a good design the path of least resistance." -David Hogue
I know that this is taken as a given in unit-test camps, but is it?
UPDATED: 1.1.2008
I found out that I am not alone in not being convinced about designing for testability. The creator of TypeMock feels that designing for testability does not comply with YAGNI.
Subscribe to:
Posts (Atom)