A Scenarios & Error Messages table documents possible situations, user actions, and the messages the system should show. It keeps responses consistent and testable.
Purpose and Benefits
- Improves UX: Clear feedback helps users recover quickly.
- Standardizes responses: Consistent wording and behavior.
- Supports dev: Developers know exact messages per scenario.
- Strengthens testing: QA can validate edge cases and errors.
- Documents edge cases: Captures rare conditions explicitly.
Scenarios & Error Messages Template
| Sr. | Case / Scenario | Action | Message | Comment |
|---|---|---|---|---|
| 1 | User enters incorrect password | User clicks login with wrong password | Invalid username or password. Please try again. | Security message should not reveal which field is incorrect |
| 2 | Email already registered | User tries to register with existing email | This email address is already registered. Please login or reset your password. | Prevent duplicate accounts |
| 3 | Password reset email not found | User enters email not registered in system | No account found with this email address. | Avoid exposing user existence details |
| 4 | Required field missing | User submits form without required field | Please fill in all required fields. | Highlight missing fields |
| 5 | Session expired | User inactive for long time | Your session has expired. Please log in again. | Security requirement |
| 6 | Payment failed | Payment gateway declines transaction | Payment could not be processed. Please try another payment method. | Log gateway error internally |
| 7 | File upload size exceeded | User uploads large file | File size exceeds the maximum allowed limit. | Limit defined by system configuration |
| 8 | Invalid input format | User enters invalid email format | Please enter a valid email address. | Input validation |
Field Explanation
- Sr.: Serial number for reference.
- Case / Scenario: Situation that occurs (e.g., invalid login, duplicate email).
- Action: User or system action that triggers the scenario.
- Message: Clear, concise, actionable text shown to the user.
- Comment: Notes for security, validation, or implementation.