how to design test cases from requiremt

How to design test cases from requirement

I will let you know how to extract good white test cases from a user story:

Example: User Story
Client wants to have a search functionality for logged in person in which a customer will perform following action
  1. Login as app user
  2. Open search link  from header or open the search tab in menu
  3. System will show search product interface
  4. Type product name in search field  
  5. Click search button or press enter
  6. System will query database and will show the products exactly matching the name  
(Optional steps)
  1. Select from   price (0 -9999)
  2. Select  To price (1-9999)
  3. User can filter  on basis of one  fields too in step 7 and 8
  4. Click Filter Link
  5. System will filter search result

Steps 1: Make a Flow chart to identify all paths

Identify all possible paths:

Few of them I am mentioning below

  1. 3> 7 >9>15
  2. 1>3>7>9>10>12>14
  3. 1>3>7>9>10>13>14>16
And this way find all possible steps and create a unique test case for every scenario

Step 2 :

Preparing test Data for fields
In product name only string inputs are allowed now make test data with is covers all possible groups

  1. Input string e.g “abcdasfasf”
  2. Input integer “1234124”
  3. Input Special characters “@#$#$”
  4. Input a mixture of string + Integer + Special character”asfasfa3453534^&%&^%FSFsdfsdf”

This way create a test data for every field which covers every positive and negative scenario

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s