Definition

Test Case

A documented set of conditions and steps used to verify that a software feature works as expected.

Full Definition

A test case is a detailed specification of inputs, execution conditions, testing procedures, and expected results that define a single test to be executed. It serves as both a guide for testers during execution and documentation of what was tested. Think of it as a recipe: it tells the tester exactly what ingredients (data) to prepare, what steps to follow, and what the dish (outcome) should look like when it's done right.


A well-written test case includes:

  • Test Case ID: Unique identifier for tracking and referencing
  • Title: Brief, descriptive summary of what's being tested
  • Preconditions: Required system state before execution begins
  • Test Steps: Sequential, unambiguous actions to perform
  • Expected Results: What should happen after each step or at the end
  • Actual Results: What actually happened (filled during execution)
  • Status: Pass, Fail, Blocked, or Skipped
  • Priority: How important this test is relative to others
  • Test Data: Specific values or datasets needed for execution
  • Environment: Browser, OS, device, or configuration details
  • Attachments: Screenshots, logs, or supporting evidence


Test cases are the fundamental building blocks of systematic testing. They ensure consistency across testers and over time, enable coverage tracking, and provide audit trails for compliance. When a new tester joins the team, well-documented test cases let them execute tests without needing tribal knowledge. When a regulator asks "how did you verify this requirement?", test cases provide the answer.


One of the most common mistakes teams make is writing test cases that are either too vague or too granular. A test case that says "verify login works" gives the tester nothing to work with — there's no indication of what data to use, what browser to test in, or what "works" actually looks like. On the other end, a test case that documents every mouse click and pixel position becomes brittle and exhausting to maintain. The sweet spot is a test case that a competent tester can follow without ambiguity, but that doesn't micromanage every interaction. Another frequent pitfall is writing test cases in isolation from the actual feature. Teams that write test cases during or immediately after requirements review — rather than after development is complete — catch ambiguities and gaps much earlier. The best QA teams treat test case writing as a collaborative act: developers, testers, and product owners review them together to make sure the acceptance criteria, edge cases, and negative scenarios are all addressed before anyone writes a line of code.


In practice, teams manage test cases differently depending on their context. Agile teams often keep test cases lightweight and update them every sprint. Teams in regulated industries (healthcare, finance, aerospace) maintain formal test cases with version control and sign-off workflows. Many teams also distinguish between "test scripts" (detailed step-by-step instructions) and "test charters" (exploratory testing goals), using both for different types of testing work.

Examples

  • 1.TC-001: Verify user can log in with valid email and password — steps include navigating to the login page, entering credentials for a known test user, clicking Submit, and confirming redirection to the dashboard with the correct welcome message displayed
  • 2.TC-002: Verify error message displays for invalid password — steps include entering a valid email with an incorrect password and confirming the specific error text "Invalid email or password" appears without revealing which field is wrong
  • 3.TC-003: Verify account lockout after 5 failed login attempts — steps include attempting login with wrong credentials five times in succession, verifying the lockout message appears, and confirming the account remains locked for the configured duration
  • 4.TC-004: Verify password reset flow sends email within 60 seconds — covers the full happy path from requesting a reset to receiving the email and successfully setting a new password
  • 5.TC-005: Verify session timeout after 30 minutes of inactivity — requires leaving the application idle and confirming redirect to login page with a "session expired" message
  • 6.TC-006: Verify login works correctly with special characters in the password field — tests passwords containing symbols like @, #, $, and unicode characters to ensure the authentication system handles them properly

In BesTest

BesTest provides structured test case creation with preconditions, numbered steps, and expected results — all stored outside of Jira issues to prevent issue bloat. The built-in review workflow lets reviewers approve or request changes before test cases are executed. Teams can organize test cases in hierarchical folders and use Smart Collections to automatically group them by tag, priority, or module.

See Test Case in Action

Experience professional test management with BesTest. Free for up to 10 users.

Try BesTest Free