Bigsun Udaan › Business analysis guides › Practice Test-Case Template
Template and worked examples
A practice test-case template
A test case is a set of steps with a clear expected result. Use this template, study the worked examples, then write your own.
The template
| Test ID | Requirement | Scenario | Pre-condition | Steps | Test data | Expected result | Actual result | Pass / Fail |
|---|---|---|---|---|---|---|---|---|
| TC-001 | ||||||||
| TC-002 | ||||||||
| TC-003 |
Worked example 1 — sign in
Requirement FR-01: An employee shall be able to sign in with a personal account.
| Test ID | Scenario | Steps | Test data | Expected result |
|---|---|---|---|---|
| TC-001 | Sign in with correct details | 1. Open the sign-in page. 2. Enter email and password. 3. Press Sign in. | A valid test account | The employee’s home page opens and shows their name. |
| TC-002 | Wrong password | 1. Open the sign-in page. 2. Enter a valid email and a wrong password. 3. Press Sign in. | Valid email, wrong password | An error message appears. The employee is not signed in. The message does not say which part was wrong. |
| TC-003 | Empty fields | 1. Open the sign-in page. 2. Leave both fields empty. 3. Press Sign in. | None | Both fields are highlighted with a message asking the user to fill them in. |
Worked example 2 — apply for leave
Requirements FR-02 and FR-04 from the sample requirements document.
| Test ID | Scenario | Pre-condition | Steps | Expected result |
|---|---|---|---|---|
| TC-010 | Valid request within balance | Employee has 5 days of balance | 1. Open “Apply for leave”. 2. Choose leave type, start date and a 2-day end date. 3. Add a reason. 4. Press Submit. | Request is saved as “Pending”. A confirmation is shown. Manager is notified. |
| TC-011 | Request exceeds balance | Employee has 1 day of balance | Submit a 3-day paid leave request. | Request is not submitted. A message says the balance is not enough. |
| TC-012 | End date before start date | Employee is signed in | Choose an end date earlier than the start date. Press Submit. | An error appears next to the date. Nothing is submitted. |
| TC-013 | Unpaid leave beyond balance | Employee has 0 days of balance | Submit a 2-day request with type “Unpaid”. | Request is accepted (as allowed by FR-04). |
Tips for good test cases
- Test the normal path, wrong inputs, empty inputs and boundary values (for example exactly 0 days of balance).
- Write steps so that someone else can repeat them exactly.
- State the expected result before you run the test.
- Link every test case to a requirement, so you can show that each requirement is checked.
Defect report template
If a test fails, record the problem clearly so it can be fixed.
| Defect ID | DEF-001 |
|---|---|
| Title | Short summary, e.g. “Request is accepted when end date is before start date” |
| Related test case | TC-012 |
| Steps to reproduce | 1. … 2. … 3. … |
| Expected result | What should have happened |
| Actual result | What really happened |
| Severity | High / Medium / Low |
| Evidence | Screenshot or note |
| Date and tester |
Practice
Write four test cases for FR-06 (a manager approves or rejects a request). Include one case where the manager leaves no comment and one where the request has already been cancelled by the employee.
Original educational material created by Bigsun Technologies for the Bigsun Udaan initiative. The people, companies and figures in the examples are fictional. This is a learning aid, not an accredited course or a guarantee of employment.