Software Testing – Do Testers Have to Look at Source Code?

testing

How necessary is it for testers to do white-box testing in addition to black-box testing? As a developer, I see value in having a QA-minded person go through my code and look for weak points, but it also seems like if a non-technical tester is thorough and methodical enough, they can cover the application well.

White box testing may reveal important test cases that wouldn't be obvious while looking only at the application from a user's perspective, but exclusively black-box testing might take less time, and significantly increases the number of people who are capable of doing the job. Also, a nontrivial amount of white box testing should be performed by the developer before it ever gets to the tester, am I right?

Best Answer

White box and black box testing are two different skills - someone skilled at one isn't necessarily skilled at the other.

A lot of what QA does will be black box testing - making sure that the system works "as advertised" and in this regard they don't need to know how the system works in order to do a good job. In fact knowledge of the code may lead them into the same traps that catch the unwary developer doing their own testing. It's far better that they have no preconceptions of how the developer thinks the system is supposed to work.

That's not to say that there shouldn't be white box testing - which is (partly) what developer unit testing is. A good suite of unit tests should be testing valid inputs, invalid inputs and edge case inputs. However, I don't think that it's always necessary for QA to do this - if for no other reason than it is really the developer's responsibility.

However, as SnOfus points out in his comments good white box testing can be extremely useful.

Related Topic