|
What "Testing aimed at showing software does not work." [Beizer] The definition shown in my opinion is too vague. Each test in negative testing needs two elements:-
Negative testing may also be referred to as "dirty testing". In terms of the V-model, negative testing runs the whole length. This is because it can be conducted during component testing through to integration testing of whole systems. In terms of other design techniques, negative testing can be seen in black box testing where there code is unavailable to the tester. White box testing with access to the code is available. Why? An example is an input field on a form. The data entered will be an amount of money to set a price field on a database. The database field accepts only numerics. Obviously the form field would need to be restricted to accept numeric characters only. If the user enters 2.37 and commits the transaction, the price will be set toŁ2.37. However what if he enters "two pounds and thirty seven pence"? Imagine that the user has entered "two pounds and thirty seven pence", if the form does not validate the data entered, once it is commited the system will try and enter alpha characters into a numeric only field on the database, this could cause the system to stall. To prevent this occuring we would:-
Once this has been demonstrated, we can be sure that the risk of a failure due to non-numeric characters being entered into the price field has been mitigated. The only problem with negative testing is the feelings it plays on and generates. Resistance can be felt against or resources not allocated for instance. Various are given:- "The customer will never do that", "it is seen negative and bad mouthing the product". In my experience negative testing is the first thing to be cut if time or money resources are tight. This is a shame as many serious problems can be uncovered, only by treating the software in a way that we should not. Who?
Where?
When?
How?
Static and dynamic analysis are can be used at the component level. Requirements are required to show how exceptions are to be handled in general and in specific circumstances. |
Test Techniques Bestsellers
The bestselling books on Amazon.
Articles
Other Related Websites
Functional Testing