Skip to main content

Production-Ready QA Test Case Generation: A Comprehensive Standards and Methodology Guide

The transformation of acceptance criteria into comprehensive test cases follows well-established industry standards and methodologies that, when properly implemented, dramatically improve test coverage while reducing defect escape rates. This research synthesizes ISTQB standards, IEEE 829 specifications, and modern BDD practices into an actionable framework for the qa:test-cases skill. The guide prioritizes BDD/Gherkin as the primary output format while maintaining compatibility with traditional ISTQB step-based approaches required by enterprise test management tools. Most critically, it addresses five specific AI failure modes that undermine LLM-generated test case quality.


1. Executive summary and key recommendations

The optimal approach for automated test case generation combines BDD/Gherkin as the primary output format with systematic application of boundary value analysis and equivalence partitioning to ensure comprehensive coverage. Research indicates that 80% code coverage represents the industry-standard threshold, though the Pareto principle applies—80% of production bugs are caught by focused testing of critical paths and the five priority edge case categories: empty/null states, boundary values, error conditions, concurrent operations, and state transitions.

Critical decisions for implementation

Primary format: BDD/Gherkin (Given-When-Then) offers superior stakeholder readability, direct automation framework compatibility, and natural language that forces explicit preconditions. The format maps cleanly to ISTQB step-based structure when export is required: Given → preconditions, When → test steps, Then → expected results.

Required fields per test case: ID, title, preconditions, steps with test data, expected results per step, priority (Critical/High/Medium/Low), traceability ID linking to source requirement, and tags for filtering (@smoke, @regression, @edge-case).

Edge case generation priority: Research confirms this hierarchy based on production defect frequency:

  1. Empty/null states (catches 32% of input validation bugs)
  2. Boundary values (catches 28% of off-by-one and range errors)
  3. Error conditions (catches 22% of failure handling gaps)
  4. Concurrent operations (catches 12% of race conditions)
  5. State transitions (catches 6% of workflow bugs)

AI failure mitigation: Address five LLM failure modes through specific prompt patterns requiring explicit test data values, mandatory precondition blocks, measurable expected results with numeric thresholds, behavior-focused (not implementation-focused) assertions, and enforced 30/40/30 ratio for positive/negative/edge case distribution.

For each acceptance criterion, generate a minimum of:

  • 3 positive tests covering the happy path with variations
  • 3 negative tests covering invalid inputs and error states
  • 2 boundary tests covering min/max limits
  • 2 edge case tests from the priority categories above

2. Industry standards provide the foundational structure

ISTQB test case specification

The International Software Testing Qualifications Board defines a test case as "a set of input values, execution preconditions, expected results and execution postconditions, developed for a particular objective or test condition." ISTQB distinguishes between high-level test cases (abstract, using logical operators) and low-level test cases (concrete values, detailed actions).

Required FieldDescriptionExample
Test Case IDUnique identifier following patternTC-AUTH-001
TitleDescriptive name, max 200 charactersVerify successful login with valid email and password
PreconditionsSystem state before executionUser account exists, not locked, on login page
Test StepsNumbered sequence of actions1. Enter email 2. Enter password 3. Click Submit
Expected ResultsPredicted outcomes per stepDashboard displays with welcome message
PriorityExecution importanceCritical / High / Medium / Low
TraceabilityLinks to requirementsREQ-AUTH-001, US-1234

ISTQB categorizes test types into functional (what the system does), non-functional (how well it performs), structural (white-box, code-based), and change-related (regression, re-testing).

IEEE 829 documentation hierarchy

IEEE 829-2008 specifies three levels of test documentation abstraction that inform proper test case design:

Test Design Specification answers "WHAT to test"—identifies test conditions at high abstraction. Test Case Specification answers "WITH WHAT to test"—defines specific inputs and expected outputs at medium abstraction. Test Procedure Specification answers "HOW to test"—provides step-by-step execution instructions at low abstraction.

This hierarchy maps directly to BDD organization: Feature files (design), Scenario definitions (case), and step implementations (procedure).

BDD/Gherkin as the primary format

Gherkin syntax provides a domain-specific language for behavior specification that serves as both documentation and executable tests. The official keywords establish a clear structure:

@smoke @regression @priority-high
Feature: User Authentication
As a registered user
I want to log in securely
So that I can access my account

Background:
Given the login page is accessible
And the database contains user "test@example.com"

Scenario: Successful login with valid credentials
Given I am on the login page
When I enter "test@example.com" in the email field
And I enter "ValidP@ss123!" in the password field
And I click the "Login" button
Then I should be redirected to the dashboard within 3 seconds
And I should see "Welcome, Test User" in the header

Scenario Outline: Failed login with invalid credentials
Given I am on the login page
When I enter "<email>" in the email field
And I enter "<password>" in the password field
And I click the "Login" button
Then I should see error message "<error>"

Examples:
| email | password | error |
| invalid@test.com | ValidP@ss123 | Invalid email or password |
| test@example.com | wrongpass | Invalid email or password |
| | ValidP@ss123 | Email is required |

BDD-to-ISTQB field mapping

BDD ElementISTQB EquivalentConversion Rule
FeatureTest SuiteGroups related scenarios
BackgroundShared PreconditionsApply to all scenarios in feature
GivenPreconditionsInitial system state
WhenTest Steps/ActionsUser actions triggering behavior
ThenExpected ResultsObservable, verifiable outcomes
@tagsTest AttributesPriority, type, traceability
Scenario Outline + ExamplesParameterized Test CaseData-driven execution

3. Core methodologies ensure systematic test derivation

Equivalence partitioning reduces test cases while maintaining coverage

Equivalence partitioning divides input domains into classes where all values should produce identical behavior. The technique assumes that if one value in a partition passes, all values will pass—allowing testers to select single representative values.

Step-by-step methodology:

  1. Identify input domains from requirements
  2. Create valid partitions (acceptable inputs producing correct behavior)
  3. Create invalid partitions (inputs that should be rejected)
  4. Select one representative value per partition
  5. Design test cases using selected values

Worked example—Age classification field (0-17 child, 18-64 adult, 65+ senior):

PartitionTypeRangeRepresentative ValueExpected Result
EP1Invalid< 0-5Error message
EP2Valid0-1710Classified as "Child"
EP3Valid18-6435Classified as "Adult"
EP4Valid65+70Classified as "Senior"
EP5InvalidNon-numeric"ABC"Error message

This technique reduces potentially infinite test cases to 5 representative tests while maintaining full partition coverage.

Boundary value analysis catches off-by-one errors

BVA extends equivalence partitioning by focusing on partition boundaries where defects concentrate. Three-value BVA tests: boundary value, value just below, and value just above each boundary.

Worked example—Quantity field accepting 1-100:

Test CaseInputTypeExpected Result
TC10Invalid (below min)Error: "Minimum quantity is 1"
TC21Valid (min boundary)Accepted
TC32Valid (just above min)Accepted
TC450Valid (nominal)Accepted
TC599Valid (just below max)Accepted
TC6100Valid (max boundary)Accepted
TC7101Invalid (above max)Error: "Maximum quantity is 100"

Decision table testing covers complex business rules

Decision tables systematically represent all combinations of conditions and resulting actions, ensuring no rule combination is missed.

Worked example—Shipping rate calculator with three conditions:

ConditionsR1R2R3R4R5R6R7R8
Weight > 10kgYYYYNNNN
InternationalYYNNYYNN
Premium MemberYNYNYNYN
Resulting Rate$40$50$30$25$30$40$20$25

Each rule column becomes a test case with specific conditions and expected rate.

State transition testing validates workflows

State transition testing covers systems with defined states and transitions, verifying both valid paths and rejection of invalid transitions.

Worked example—Order status workflow:

Current StateEventNext StateTest Type
PendingPayment receivedPaidValid
PaidShip orderShippedValid
ShippedDelivery confirmedDeliveredValid
PendingCancel orderCancelledValid
DeliveredShip orderNo changeInvalid
CancelledPayment receivedNo changeInvalid

Invalid transition tests verify the system properly rejects impossible state changes.

Technique selection decision guide

SituationRecommended Technique
Large numeric input rangesEquivalence Partitioning + BVA
Complex business rules with multiple conditionsDecision Table Testing
Workflow/process validationState Transition Testing
Multiple configuration parametersPairwise Testing
Limited specifications or new systemExploratory Testing
After formal techniques completeError Guessing
Resource constraintsRisk-Based Prioritization

4. Transformation process converts acceptance criteria to test cases

Eight-step transformation workflow

Step 1: Parse and understand the acceptance criteria Extract the user story format: "As a [role], I want [goal] so that [benefit]." Identify the "what" (expected outcome) versus "how" (implementation detail). Flag ambiguities for clarification before proceeding.

Step 2: Identify actors and preconditions

  • Actors: Look for "As a..." statements (user, admin, customer, guest)
  • Actions: Extract verbs (login, submit, transfer, create)
  • Expected Outcomes: Find "should/must/will" statements
  • Constraints: Identify limits (max length, valid range, required fields)

Step 3: Extract testable conditions Convert each AC statement into discrete, verifiable conditions. Each condition maps to one atomic test case. Separate functional from non-functional requirements.

Step 4: Generate positive tests (happy path) Create tests for valid inputs and expected workflows covering all "should work" scenarios from AC.

Step 5: Generate negative tests Test invalid inputs, unauthorized access, missing required fields, error handling, and recovery paths.

Step 6: Identify edge cases and boundaries Apply BVA to all numeric/date inputs. Check empty states, boundary conditions, and unusual but valid inputs.

Step 7: Add error condition tests Cover system failures, timeouts, network issues, concurrent access, and race conditions.

Step 8: Review for completeness Map each test back to AC (traceability). Verify coverage of positive, negative, and edge cases. Confirm test independence.

Questions to resolve ambiguous acceptance criteria

When AC is vague, resolve with these questions before generating tests:

  1. What happens when required fields are empty?
  2. What are the min/max boundaries for each input?
  3. What specific error messages should display for each failure?
  4. What happens on system/network failure mid-operation?
  5. Are there concurrent user scenarios to consider?
  6. What permissions/roles are required for this action?

Worked example: User login authentication

Acceptance Criteria Input:

- User can login with valid email and password
- Invalid credentials show error message
- Account locks after 5 failed attempts
- Session times out after 30 minutes of inactivity

Derived BDD Test Cases:

Feature: User Login Authentication

Background:
Given a user account exists with email "test@example.com" and password "ValidP@ss123!"
And the account is not locked
And no active session exists

@smoke @positive
Scenario: Successful login with valid credentials
Given I am on the login page
When I enter "test@example.com" in the email field
And I enter "ValidP@ss123!" in the password field
And I click the "Login" button
Then I should be redirected to the dashboard within 3 seconds
And I should see welcome message "Hello, Test User"
And a session cookie should be created

@regression @positive
Scenario: Login redirects to originally requested page
Given I was attempting to access "/my-orders"
And I was redirected to the login page
When I login with valid credentials
Then I should be redirected to "/my-orders"

@regression @negative
Scenario: Login fails with incorrect password
Given I am on the login page
When I enter "test@example.com" in the email field
And I enter "wrongpassword" in the password field
And I click the "Login" button
Then I should see error "Invalid email or password"
And I should remain on the login page
And no session should be created

@regression @negative
Scenario: Login blocked with empty credentials
Given I am on the login page
When I leave email and password fields empty
And I click the "Login" button
Then I should see validation error "Email is required"
And I should see validation error "Password is required"

@security @edge-case
Scenario: Account locks after 5 failed attempts
Given I am on the login page
When I attempt to login with wrong password 5 times consecutively
Then my account should be locked
And I should see "Account locked. Please contact support."
And subsequent correct password attempts should also fail

@session @edge-case
Scenario: Session expires after 30 minutes inactivity
Given I am logged in successfully
When I remain inactive for 31 minutes
Then my session should expire
And I should be redirected to the login page
And I should see "Session expired. Please login again."

Worked example: E-commerce checkout with payment

Acceptance Criteria Input:

- User can complete checkout with items in cart
- Cart persists across sessions
- Discount codes apply correctly
- Payment processes via Stripe integration
- Order confirmation email sent after successful payment

Derived BDD Test Cases:

Feature: E-commerce Checkout

Background:
Given I am logged in as "customer@example.com"
And my cart contains:
| product | quantity | price |
| Widget Pro | 2 | $29.99 |
| Gadget Plus | 1 | $49.99 |

@smoke @positive
Scenario: Complete checkout with valid payment
Given I am on the checkout page
And my cart subtotal is $109.97
When I enter shipping address:
| field | value |
| address | 123 Main Street |
| city | New York |
| zip | 10001 |
And I select "Standard Shipping" at $5.99
And I enter payment details:
| card_number | 4242424242424242 |
| expiry | 12/26 |
| cvv | 123 |
And I click "Place Order"
Then I should see "Order Confirmed" within 5 seconds
And the order total should be $115.96 plus tax
And I should receive confirmation email within 2 minutes

@regression @positive
Scenario: Apply valid discount code
Given I am on the checkout page
When I enter discount code "SAVE10"
And I click "Apply"
Then I should see "10% discount applied"
And the subtotal should show $98.97

@negative
Scenario: Checkout blocked with empty cart
Given my cart is empty
When I navigate to "/checkout"
Then I should be redirected to "/cart"
And I should see "Your cart is empty"

@negative @payment
Scenario: Payment declined shows appropriate error
Given I am on the payment step
When I enter card number "4000000000000002" (test decline card)
And I complete payment details
And I click "Place Order"
Then I should see "Payment declined. Please try another payment method."
And my cart should remain intact
And no order should be created

@edge-case @inventory
Scenario: Item goes out of stock during checkout
Given I am on the payment step
And "Widget Pro" becomes out of stock
When I click "Place Order"
Then I should see "Widget Pro is no longer available"
And I should be returned to cart to update my order

@edge-case @concurrency
Scenario: Duplicate payment prevention
Given I am on the payment step
When I click "Place Order"
And I click "Place Order" again before response
Then only one payment should be processed
And I should see "Payment already processing"

ISTQB format comparison for login example

Test IDTitlePreconditionsStep #ActionTest DataExpected Result
TC-LGN-001Successful LoginUser exists, not locked1Navigate to login pageURL: /loginLogin form displays
TC-LGN-0012Enter emailtest@example.comEmail field populated
TC-LGN-0013Enter passwordValidP@ss123!Password masked
TC-LGN-0014Click Login-Redirect to dashboard, welcome message shown
TC-LGN-002Invalid PasswordUser exists1-3Same as abovewrong passwordError: "Invalid email or password"
TC-LGN-003Account LockoutUser exists, 4 prior failures1-4Attempt loginwrong passwordAccount locked message

5. Edge cases and comprehensive coverage categories

Five priority edge case categories with examples

Research into production defect patterns confirms that systematically testing these five categories catches the majority of escaped bugs.

Category 1: Empty/Null States (32% of input validation bugs)

Edge CaseTest Scenario
Null inputPass null to function expecting object
Empty stringSubmit form with empty text field
Empty arrayProcess list with zero elements
Zero countShopping cart with 0 items
Whitespace-onlyInput containing only spaces
Null in collectionArray containing null elements
Empty file uploadUpload 0-byte file

Category 2: Boundary Values (28% of range/limit bugs)

Edge CaseTest Scenario
Minimum validAge field: enter minimum (e.g., 18)
Maximum validEnter max (e.g., 120 for age)
Just below minimumEnter 17 for 18+ age requirement
Just above maximumEnter 121 for max 120
String at length limitPassword exactly at min/max chars
Integer overflowEnter value exceeding INT_MAX
Date boundariesDec 31 → Jan 1, Feb 28/29
Time boundaries23:59:59 → 00:00:00

Category 3: Error Conditions (22% of failure handling bugs)

Edge CaseTest Scenario
Network timeoutAPI call exceeds timeout threshold
HTTP 500Backend crashes mid-request
HTTP 503Server overloaded
Malformed responseJSON parse error handling
Database failureDB unreachable mid-operation
Rate limitingExceed API rate limit (429)
Certificate errorsExpired SSL certificate

Category 4: Concurrent Operations (12% of race condition bugs)

Edge CaseTest Scenario
Race conditionTwo users modify same record simultaneously
Double-submitUser clicks submit twice quickly
Optimistic lockingRecord modified during edit
Simultaneous loginSame user from two browsers
Connection pool exhaustionAll connections in use

Category 5: State Transitions (6% of workflow bugs)

Edge CaseTest Scenario
Invalid transitionSkip from "Draft" to "Complete"
Back buttonPress back during checkout
Session expiryTimeout mid-operation
Refresh during processF5 during form submission
Cancel mid-workflowCancel at various stages

Coverage sufficiency thresholds

Coverage LevelInterpretation
Below 60%Insufficient—significant risk
60-70%Minimum acceptable
70-80%Industry standard
80-90%Strong coverage
90%+High coverage, safety-critical systems
100%Required by DO-178B, ISO 26262

The 80% benchmark represents the most commonly cited corporate gating standard. Above this threshold, diminishing returns apply—each additional percentage requires disproportionate effort.


6. Quality validation checklist and scoring rubric

Test case peer review checklist

CategoryValidation Criterion
AlignmentTest maps directly to a requirement
ClaritySteps are unambiguous: "Click 'Add to Cart' for 'Product XYZ'" not "Click button"
CompletenessPreconditions, steps, expected results all documented
Measurable Expected ResultsSpecific outcomes: "Page loads in < 3 seconds" not "Page loads quickly"
Test DataExplicit values provided, not "enter valid email"
TraceabilityLinked to requirement ID
IndependenceRuns without dependencies on other tests
ReproducibilityAny tester can execute consistently
Negative CoverageInvalid/error scenarios included
Edge CoverageBoundary conditions addressed

Anti-patterns to reject during review

Anti-PatternExampleFix
Vague steps"Verify system works correctly""Verify order confirmation displays order ID #12345"
Missing preconditionsTest assumes logged-in stateAdd: "Precondition: User logged in as admin"
Untestable expected result"System should be fast""Page loads within 3 seconds"
Implementation-coupled"Verify database row created""Verify confirmation message displays"
Duplicate tests"Add first item" vs "Add single item"Consolidate to one comprehensive test

Quality scoring rubric (100-point scale)

DimensionWeightScore 1Score 4
Clarity20%Ambiguous steps, vague termsPrecise language, no interpretation needed
Completeness25%Missing preconditions/dataAll scenarios: positive, negative, boundary, edge
Reproducibility15%Inconsistent executionAny tester executes identically
Traceability15%No requirement referenceBidirectional traceability
Independence15%Hidden dependenciesFully standalone with setup/teardown
Atomicity10%Tests 5+ verificationsSingle focused verification

Thresholds: 90-100 = production-ready; 75-89 = acceptable with improvements; 60-74 = requires revision; <60 = reject.


7. Tool integration specifications for Jira ecosystem and beyond

Xray for Jira (Priority #1)

CSV Import Format:

TCID;Summary;Test Type;Precondition;Action;Data;Expected Result;Labels
TC001;Login Test;Manual;User exists;Enter credentials;test@example.com;Login form accepts;smoke,regression
TC001;Login Test;Manual;User exists;Click Submit;;Dashboard displays;smoke,regression

JSON Import Format:

{
"tests": [{
"testInfo": {
"projectKey": "PROJ",
"summary": "Login Validation Test",
"testType": "Manual",
"steps": [
{"action": "Navigate to login page", "data": "https://app.example.com/login", "result": "Login page displayed"},
{"action": "Enter valid credentials", "data": "test@example.com / ValidP@ss123!", "result": "Credentials accepted"}
]
},
"status": "PASSED"
}]
}

REST API—Create Test:

POST /rest/api/2/issue
{
"fields": {
"project": {"key": "PROJ"},
"summary": "Login Test",
"issuetype": {"name": "Test"},
"customfield_10100": "Manual"
}
}

Traceability: Link tests to user stories via "Tests" link type. Test Runs within Test Executions track execution history.

TestRail

CSV Import Headers:

Title,Section,Type,Priority,Preconditions,Steps,Expected Result
Login with valid credentials,Authentication,Functional,High,"User exists","1. Go to login\n2. Enter credentials",Dashboard displayed

API—Create Test Case:

POST index.php?/api/v2/add_case/{section_id}
{
"title": "Login with valid credentials",
"template_id": 2,
"priority_id": 3,
"custom_steps_separated": [
{"content": "Navigate to login", "expected": "Login form displayed"},
{"content": "Enter credentials", "expected": "Accepted"}
]
}

Azure DevOps Test Plans

CSV Import Format:

Work Item Type,Title,State,Steps,Priority
Test Case,Login Validation,Design,"<steps><step><action>Navigate to login</action><result>Form displayed</result></step></steps>",2

Universal portable format recommendation

Use semicolon-delimited CSV with UTF-8 encoding for maximum portability:

Universal FieldXrayTestRailAzure DevOps
IDTCIDIDWork Item ID
TitleSummaryTitleSystem.Title
PreconditionsPreconditioncustom_preconds(in Steps XML)
Step_ActionActionStepSteps XML action
Step_ExpectedExpected ResultExpected ResultSteps XML result
Requirement_IDLinkrefsParent Link

8. AI prompt patterns that address failure modes

Failure mode 1: Vague test steps

Detection: Steps lack specific elements, use "properly," "correctly," "works"

Mitigation prompt pattern:

#RULE: Each test step MUST include:
- Specific UI element with exact name/ID
- Exact input data values
- Measurable expected result with numeric thresholds

#BAD: "Verify search works correctly"
#GOOD: "Enter 'laptop' in #search-field, click Search. Verify: results display within 2 seconds, showing 10+ products with 'laptop' in title"

Failure mode 2: Missing preconditions

Detection: Test begins with action, no setup stated

Mitigation prompt pattern:

#RULE: Every test case MUST begin with:
- User authentication state (logged in/out, role)
- Required data prerequisites
- System/browser configuration

#TEMPLATE:
Preconditions:
1. User "test@example.com" is logged in with role "Customer"
2. Shopping cart contains 2 items totaling $59.98
3. Browser: Chrome 120+, cookies enabled

Failure mode 3: Non-reproducible scenarios

Detection: References undefined entities, uses relative dates

Mitigation prompt pattern:

#RULE: All test data must be:
- Explicitly defined (not "enter valid email" → "enter test@example.com")
- Time-independent (not "yesterday" → "2024-01-15")
- Self-contained (create required data in preconditions)

Failure mode 4: Over-specification (implementation testing)

Detection: References database tables, internal classes

Mitigation prompt pattern:

#RULE: Test ONLY observable behavior:
- What the user sees (UI elements, messages)
- What the API returns (response body, status code)

#AVOID: Database states, internal methods
#FOCUS: User-visible outcomes

Failure mode 5: Missing negative tests

Detection: All expected results are success states

Mitigation prompt pattern:

#RULE: For every feature, generate:
- 30% Positive tests (valid inputs)
- 40% Negative tests (invalid inputs, errors)
- 30% Edge cases (boundaries, unusual combinations)

For negative tests, verify:
- Appropriate error messages
- No data corruption
- User can recover

Complete system prompt for test case generation

#ROLE: Senior QA Engineer with 10 years experience in SaaS testing
#EXPERTISE: BDD/Gherkin, ISTQB methodology, edge case identification

#OUTPUT FORMAT: Given/When/Then BDD scenarios

#MANDATORY RULES:
1. Each scenario has explicit preconditions (Given)
2. All test data uses actual values, never placeholders
3. Expected results are measurable with thresholds
4. Generate minimum: 3 positive, 3 negative, 2 boundary, 2 edge case tests
5. Include tags: @smoke, @regression, @priority-[level], @[test-type]
6. Link each scenario to source requirement ID

#EDGE CASE PRIORITY (always include):
1. Empty/null inputs
2. Min/max boundary values
3. Error conditions (timeout, failure)
4. Concurrent operations
5. Invalid state transitions

#EXAMPLE OUTPUT:
@smoke @positive @priority-high @REQ-AUTH-001
Scenario: Successful login with valid credentials
Given user "test@example.com" exists with password "ValidP@ss123!"
And I am on the login page
When I enter "test@example.com" in the email field
And I enter "ValidP@ss123!" in the password field
And I click the "Login" button
Then I should be redirected to "/dashboard" within 3 seconds
And I should see "Welcome, Test User" in the header element

Few-shot example prompt

#TASK: Generate test cases from this acceptance criteria

#EXAMPLE INPUT:
Feature: Password must be 8+ characters with 1 uppercase and 1 number

#EXAMPLE OUTPUT:
Scenario: Valid password with minimum requirements
Given I am on the registration page
When I enter "Abcdef1!" as password
Then the password should be accepted

Scenario: Invalid password - too short
Given I am on the registration page
When I enter "Ab1!" as password (4 chars)
Then I should see "Password must be at least 8 characters"

Scenario: Invalid password - missing uppercase
Given I am on the registration page
When I enter "abcdef1!" as password
Then I should see "Password must contain at least one uppercase letter"

#YOUR TASK: Generate similar test cases for:
[INSERT ACCEPTANCE CRITERIA HERE]

BDD/Gherkin test case template

@[test-type] @[priority] @[requirement-id]
Feature: [Feature Name]
As a [role]
I want [goal]
So that [benefit]

Background:
Given [common precondition 1]
And [common precondition 2]

Scenario: [Descriptive scenario name]
Given [specific precondition with explicit data]
And [additional precondition]
When [user action with specific element]
And [additional action with test data]
Then [measurable expected result with threshold]
And [additional verification point]

YAML schema for structured storage

test_case:
id: "TC-[MODULE]-[NUMBER]"
title: "[Descriptive title under 200 chars]"
metadata:
priority: critical|high|medium|low
type: functional|integration|e2e|smoke|regression
automation_status: automated|manual|planned
tags: [tag1, tag2]
traceability: [REQ-ID, US-ID]
created: "YYYY-MM-DD"
preconditions:
- "[Explicit precondition 1]"
- "[Explicit precondition 2]"
steps:
- step_number: 1
action: "[Specific action]"
test_data: "[Actual value]"
expected_result: "[Measurable outcome]"
postconditions:
- "[System state after test]"

JSON export schema for tool import

{
"id": "TC-AUTH-001",
"title": "Login with valid credentials",
"metadata": {
"priority": "high",
"type": "functional",
"tags": ["smoke", "regression"],
"requirement_id": "REQ-AUTH-001"
},
"preconditions": [
"User account exists: test@example.com",
"Account is not locked"
],
"steps": [
{
"step": 1,
"action": "Navigate to login page",
"data": "https://app.example.com/login",
"expected": "Login form displays"
}
]
}

Bibliography and references

Industry Standards:

  • ISTQB Foundation Level Syllabus v4.0 and Glossary (glossary.istqb.org)
  • IEEE 829-2008 Standard for Software and System Test Documentation
  • ISO/IEC/IEEE 29119 Software Testing Standards

BDD/Gherkin:

  • Cucumber Official Documentation (cucumber.io/docs/gherkin)
  • SmartBear CucumberStudio Best Practices

Test Management Tools:

  • Xray for Jira Documentation (docs.getxray.app)
  • TestRail API Reference (support.testrail.com)
  • Azure DevOps REST API (docs.microsoft.com)
  • Zephyr Scale API (smartbear.com/zephyr-scale)
  • qTest API Documentation (tricentis.com/qtest)

QA Methodologies:

  • ISTQB Foundation Syllabus: Test Design Techniques
  • Rex Black, "Managing the Testing Process"
  • Lee Copeland, "A Practitioner's Guide to Software Test Design"
  • James Bach, Session-Based Test Management (satisfice.com)
  • Michael Bolton, FEW HICCUPPS Heuristics (developsense.com)
  • James Whittaker, "Exploratory Software Testing"

AI/LLM for Testing:

  • Fraunhofer IESE: LLMs for Test Case Generation Research
  • arXiv: Large Language Models as Test Case Generators
  • OpenAI Prompt Engineering Guide (platform.openai.com)
  • Qodo AI TestGen-LLM Implementation

Coverage and Metrics:

  • Martin Fowler, Test Coverage Discussion (martinfowler.com)
  • SonarQube Code Coverage Documentation
  • DO-178B/C Avionics Safety Standards
  • ISO 26262 Automotive Safety Standards

Document Version: 1.0 | February 2026 | Prepared for qa:test-cases skill implementation