Test Cases

What is Test Case?

  • A test case is a set of predefined operations performed to verify the specific functionality or feature of a software application.
  • Test cases include specific inputs already defined and mentioned in the Test Case document and results generated against them to make sure the particular feature is working correctly or not.
  • Test engineers can use these variables or conditions to match expected results with the actual results to conclude whether the software application or product is operating under the client requirements or not.

What are the elements and attributes of Test Cases

Following are the essential elements and must be required for writing a test case document.

  1. Test Case ID
  2. Test Case Description
  3. Test Steps
  4. Test Data
  5. Testing Environment
  6. Expected Result
  7. Actual Result
  8. Status
  9. Comments

How to Document Test cases

Test Case ID

ID or number for the test case.                                    

Test Case Description     

Summary or purpose of the test case.           

Test Steps                                       

If any steps required to execute the test case

Test Data                                         

Data for testing and evaluating the test case

Testing Environment

Testing environment should be mentioned while writing test cases. For Example specific browser, device or screen resolution.

Expected Result                         

Result according to the requirement document/                                                                    Assumed output of the system

Actual Result                               

Result generated by the software or actual output

Status                                               

Pass or Fail. Defines test case pass or not

Comments                                    

Important note while executing the test case

Sample Example For Writing Test Case

Test Case                                           

ID TC-1001

Test Case Description                

User should be login successfully on clicking on the login button by entering a valid user name and password.

Test Steps                                          

Go to Home page.

Click on the login link.

Test Data                                           

Add registered User Name

Add valid password

Expected Result                            

User should be login to the app.

Actual Result                                  

User login successfully

Status                                                

Pass

Comments                                        

No Remark.

Characteristics of a good test case

  1. A test case is written must be simple and transparent.
  2. No need to add extra content.
  3. Test case must be unique.
  4. Test cases easily traceable to requirements.
  5. Do suppose or assume by your self.
  6. Cover all software requirements defined in the specification document.
  7. Make sure to cover all positive and negative scenarios.
  8. No grammar mistakes.
  9. No spelling mistakes.

Leave a Comment

Your email address will not be published. Required fields are marked *