News for hackers. Stuff that matters.
Re:Cover your PHP legacy code with 1000 unit tests in just f... by waps on Friday September 20, 2013 @01:22PM (#6419114)
Bleh. That definition of unit tests is so bland as to not differentiate between any kind of testing. That definition explicitly states that having a person (like QA?) go through the app and see what happens also constitutes unit testing. And that's bullshit, manual testing is not unit testing. And neither is testing an entire module at a time.

A useful discussion on the terminology problem can be found here: http://c2.com/cgi/wiki?StandardDefinitionOfUnitTest

Most definitions define unit testing as testing the "smallest piece of code that can be tested in isolation". Then my criticism definitely applies.

And given my code reviews, it's obvious that the vast majority of programmers see unit testing as testing every individual function/method in isolation. This actually hides problems by increasing total source code (actual code and the tests + "compromises" for testability) and locks down internal structure of supposedly encapsulated logic. Both are very, very bad things.

There are no comments on this comment yet.