Software Testing Test Cases and Plans

Test cases and test plans are the core documents that structure a testing effort. Without them, testing is unpredictable, incomplete, and impossible to measure. With them, every tester knows what to test, how to test it, and what a passing result looks like.

What Is a Test Case?

A test case is a documented set of steps that a tester follows to check a specific behaviour of the software. Each test case describes the input, the action, and the expected outcome.

  A test case answers three questions:
  ┌──────────────────────────────────────────┐
  │ WHAT do I do?    → Steps to follow       │
  │ WITH WHAT?       → Input data            │
  │ WHAT SHOULD HAPPEN? → Expected result    │
  └──────────────────────────────────────────┘

Anatomy of a Test Case

  ┌──────────────────────────────────────────────────────────┐
  │ Test Case ID:    TC_LOGIN_001                            │
  │ Test Title:      Login with valid credentials            │
  │ Module:          User Authentication                     │
  │ Priority:        High                                    │
  │ Precondition:    User is on the Login page               │
  │                                                          │
  │ Steps:                                                   │
  │   1. Enter email: user@email.com                         │
  │   2. Enter password: TestPass@1                          │
  │   3. Click "Login" button                                │
  │                                                          │
  │ Expected Result: User is redirected to Dashboard.        │
  │                  Welcome message shows user's name.      │
  │                                                          │
  │ Actual Result:   [Filled in during execution]            │
  │ Status:          Pass / Fail                             │
  │ Tester Name:     [Name]                                  │
  │ Date Executed:   [Date]                                  │
  └──────────────────────────────────────────────────────────┘

Types of Test Cases

Positive Test Cases

Tests that use valid, expected inputs to confirm the software works under normal conditions.

  Enter a valid 10-digit phone number → System accepts it ✔

Negative Test Cases

Tests that use invalid, unexpected, or extreme inputs to confirm the software handles errors gracefully.

  Enter letters in a phone number field → System shows error ✔
  Enter 5-digit phone number           → System shows error ✔
  Leave phone number field empty       → System shows error ✔

Edge Case Test Cases

Tests that use values at the extremes of what the software is designed to handle.

  Minimum allowed password length: 8 characters
  → Test with exactly 8 characters       → Should pass
  → Test with exactly 7 characters       → Should fail

What Is a Test Plan?

A test plan is a document that describes the entire testing approach for a project. It is written before testing begins and guides the whole team through the testing effort.

  Test Plan answers:
  ──────────────────────────────────────────────────
  ✔ What will be tested? (Scope)
  ✔ What will NOT be tested? (Out of scope)
  ✔ Who will do the testing? (Roles)
  ✔ What tools will be used?
  ✔ What environments are needed?
  ✔ What is the schedule?
  ✔ What risks could affect testing?
  ✔ When is testing considered complete? (Exit criteria)

Key Sections of a Test Plan

1. Test Objectives

Defines what the testing effort is trying to achieve. For example: "Verify that all payment flows work correctly before the v2.0 launch on 15 March."

2. Scope

Lists the features and areas that will be tested, and explicitly states what is out of scope (so no one assumes it is covered).

3. Test Strategy

Describes the approach — which types of testing will be used, which tools, and how automation and manual testing will be divided.

4. Resources and Roles

Names the testers, their responsibilities, and the tools and environments they will use.

5. Schedule

Defines the timeline — when each phase of testing begins, milestones, and the planned go/no-go decision date.

6. Risk and Mitigation

Identifies potential risks (e.g., "Test environment may not be ready in time") and plans to reduce their impact.

7. Entry and Exit Criteria

States when testing can begin and when it can be declared complete.

Test Case vs Test Plan vs Test Suite vs Test Script

  TERM           WHAT IT IS
  ────           ──────────
  Test Case      One specific check with steps and expected result
  Test Suite     A collection of related test cases grouped together
  Test Plan      The full strategy document for a testing project
  Test Script    Automated code that executes a test case

Writing Effective Test Cases: Key Tips

  • Write each test case to check one thing only. Multiple assertions in one case make failures hard to diagnose.
  • Use clear, specific steps. "Go to the login page" is clearer than "Navigate to the authentication section."
  • Include both the preconditions and the expected result. Without them, two testers may execute the same test in two different ways.
  • Number and name your test cases so they are easy to reference in bug reports.
  • Review test cases with the developer or business analyst to make sure they reflect accurate requirements.

Leave a Comment

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