Monday, May 4, 2009

Designing Test Cases

Designing Test Cases

There are various techniques in which you can design test cases. For example, the below illustrated gives you an overview as to how you derive test cases using the basis path method:

The basis path testing method can be applied to a procedural design or to source code. The following steps can be applied to derive the basis set:

1. Use the design or code as a foundation, draw corresponding flow graph.

2. Determine the Cyclomatic complexity of the resultant flow graph.

3. Determine a basis set of linearly independent paths.

4. Prepare test cases that will fore execution of each path in the basis set.

 

Let us now see how to design test cases in a generic manner:

1.        Understand the requirements document.

2.        Break the requirements into smaller requirements (if it improves your testability).

3.        For each Requirement, decide what technique you should use to derive the test cases. For example, if you are testing a Login page, you need to write test cases basing on error guessing and also negative cases for handling failures.

4.        Have a Traceability Matrix as follows:

Requirement No (In RD)

Requirement

Test Case No

 

 

 

 

What this Traceability Matrix provides you is the coverage of Testing.  Keep filling in the Traceability matrix when you complete writing test case's for each requirement.

No comments:

Post a Comment