Negative Vs. Positive Testing

February 7, 2019
John Kensinger
John Kensinger

While there are many types of software testing, two basic and paramount categories are Positive and Negative Testing.

Positive Testing

Positive Testing is a type of testing whereby a valid data set is entered as the input. In this case, it confirms whether or not software is working as expected by using positive inputs. In short, this form of testing seeks to confirm that the software does exactly what it’s supposed to do.

For example, let’s say you have a text box that will turn green when you enter numbers. If you enter three numbers, the box should turn green. If it does, then that would be an accepted positive test. If it doesn’t, then it has failed the positive test; in other words, it doesn’t work as expected or as it should.

Negative Testing

On the other hand, Negative Testing is a type of testing whereby an invalid data set is entered as the input. In this case, it confirms that the software is not working as expected by using negative, or incorrect, inputs. This form of testing confirms that the software does not do anything it should not do with the incorrect input.

Using the same text box example from above, say you enter three letters instead of numbers. The box should not turn green. If it does turn green, that would be a failed negative test; in other words, if numbers are not entered, it should not turn green.

Two Parameters

Both types of testing are most commonly applied in test cases and typically entail two parameters, boundary value analysis and equivalence partitioning.

Boundary Value Analysis

Boundary value analysis is a technique whereby tests are designed with preset boundary values in a range. This prevents input values from being placed at extreme ends of the input domain (the farther apart they appear, the greater the chance of system error). Thus, the focus of boundary value analysis is to find the errors existing at the boundaries as opposed to the center.

Equivalence Partitioning

Equivalence partitioning entails separating input data into partitions of equivalent data from which test cases can be selected. This parameter seeks to define types of errors (trends) found in test cases in order to reduce the total amount of cases that must be written out.

When to use each one?

Many critics argue that negative testing is too similar to positive testing to provide any sort of novel insight. However, while similar, they are certainly not identical, and using both forms of testing in tandem can allow for the most comprehensive testing measure. While positive testing affirms that the given use case is valid, or correct, negative testing can prove that the software is devoid of issues that may deter a customer from successfully utilizing it.

Read More

June 13, 2019
The Important of Manual-Stage Testing

Incorporating manual testing into your development pipeline, without bottlenecks.

June 7, 2019
Regression Testing: Where Does Crowdtesting Fit In?

What is regression testing, and how does crowdtesting benefit it?

May 30, 2019
HUM Nutrition: A Test a Day Keeps the Bugs Away

test IO helps HUM Nutrition provide customers with life-changing products.

Ship Faster, Sleep Better

Get a Demo
testIO Logo Footer
test IO Inc.
1111 Broadway, Floor 3 
Oakland, CA 94607
USA

test IO GmbH
Sonnenallee 223 a
12059 Berlin
Deutschland
twitterfacebooklinkedin