To calculate the square root of a number, the equivalence classes will be:
(a) Valid inputs:
Whole number which is a perfect square- output will be an integer.
Whole number which is not a perfect square- output will be decimal number.
Positive decimals.
(b) Invalid inputs:
Negative numbers(integer or decimal).
Characters other that numbers like “a”,”!”,”;”,etc.
3. Boundary value analysis – boundaries are very good places for errors to occur. Hence if test cases are designed for boundary values of input domain then the efficiency of testing improves and probability of finding errors also increase. For example – If valid range is 10 to 100 then test for 10,100 also apart from valid and invalid inputs.
4. Cause effect Graphing –
This technique establishes relationship between logical input called causes with corresponding actions called effect. The causes and effects are represented using Boolean graphs. The following steps are followed:
- Identify inputs (causes) and outputs (effect).
- Develop cause effect graph.
- Transform the graph into decision table.
- Convert decision table rules to test cases.
For example, in the following cause effect graph:
It can be converted into decision table like:
Each column corresponds to a rule which will become a test case for testing. So there will be 4 test cases.
5. Requirement based testing -
It includes validating the requirements given in SRS of software system.
6. Compatibility testing –
The test case result not only depend on product but also infrastructure for delivering functionality. When the infrastructure parameters are changed it is still expected to work properly. Some parameters that generally affect compatibility of software are:
- Processor (Pentium 3,Pentium 4) and number of processors.
- Architecture and characteristic of machine (32 bit or 64 bit).
- Back-end components such as database servers.
- Operating System (Windows, Linux, etc).