Question

Can you think of any disadvantages of White Box testing - other that the tester needs to know and understand the code (which may have a cost)?

Thanks,

Was it helpful?

Solution

It is both an advantage and disadvantage as you're creating your tests to test the specific code implementation instead of designing tests to test how it will be used in a real situation. So basically it is a disadvantage that it does not catch all cases of use, which is why black box testing is a good compliment to whit box.

OTHER TIPS

IMHO, The main disadvantage is that your test plan, execution, and coverage is more susceptible to changes in the underlying implementation, and is thus less useful for regression and acceptance testing.

White box testing is useful at lower-levels and in addition to black-box tests, but I would be nervous if I was due to deliver software with only white-box tests.

Advantages of Black-box testing

  • Since tester does not have to focus on the inner working of an application, creating test cases is easier.
  • Test case development is faster as tester need not to spend time on identifying the inner processes; his only focus is on the various paths that a user may take through GUI.
  • It is simple to use as it focuses only on valid and invalid inputs and ensures that correct outputs are obtained.

Drawbacks of Black-box testing

  • Constantly changing GUI makes script maintenance difficult as the input may also be changing.
  • Interacting with GUI may result in making the test script fragile and it may not properly execute consistently.

Advantages of White-box testing

  • Since the focus is on the inner working the tester can identify objects pro grammatically. This can be useful when the GUI is frequently changing.
  • It can improve stability and re usability of test cases provided the object of an application remains the same.
  • By testing each path completely it is possible for a tester to achieve thoroughness.

Drawbacks of White-box testing

  • Developing test cases for white-box testing involves high degree of complexity therefore it requires highly skilled people to develop the test cases.
  • Although to a great extent fragility is overcome in white-box testing BUT change in the objects name may lead to breaking of the test script.

The biggest disadvantage of White Box testing IMHO, is the time it takes. Programmer and tester time is expensive. Better to catch the big show-stopping bugs first with broader testing methods.

Some thoughts about two previous assessments:

disadvantages ... the tester needs to know and understand the code

test plan, execution, and coverage is more susceptible to changes in the underlying implementation

It depends on whether the developers also assume a testing implementation role. That is, if the developers are supposed to understand the testing framework or architecture and are responsible for writing internal test taps and hooking them up properly, then the tests are still white-box, but without most of the disadvantages we usually think of. In such a case, the disadvantage would be that it is difficult to find qualified developers, or that it will shift the developer and tester's responsibility.

Recent trends, like test driven, agile, etc, are more and more promoting developer testing. One step further, would be to hook up the testing framework to unit tests. In this sense, the disadvantage of white-box would be, organizational chaos caused by role changes in people.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top