015 – Live Project (Part 8): Test Cases for Registration Form - rkb-sdet/SoftwareTesting GitHub Wiki
Session 15 – Live Project (Part 8): Test Cases for Registration Form
Test Cases - Registration
Doc -1. Project Context & Progress Recap
- This is an Independent Software Testing Live Project, step-by-step from project initiation → exploration → requirement & doubt clarification → test planning → scenarios → test case template, and now actual test case authoring.
- Current focus: Practically designing comprehensive test cases for the Registration Form scenario—using the template and real-world thinking.
2. Test Case Authoring Approach
- Each scenario (e.g., Registration form) can have many distinct test cases—covering positive, negative, edge, UI, usability, and environment aspects.
- Use the prepared test case template (from last session) for uniformity, clarity, and easy review.
- Every test case traces to a scenario for coverage mapping.
3. Example Registration Test Cases (High-Level List)
These cover most common and critical paths users may attempt.
A. Positive Flow
- Register account by providing only mandatory fields (first name, last name, email, password, telephone & privacy policy).
- Register account by providing all fields (including newsletter, etc.).
- Register account with newsletter selected (“Yes”).
- Register account with newsletter not selected (“No”).
- Register using keyboard only (no mouse; accessibility check).
B. Negative/Validation Flows
- Try to register without entering any fields—should receive error messages for all mandatory fields.
- Register with only spaces in mandatory fields—validation/error.
- Register account with existing account details (duplicate email)—should get error "Email address already exists."
- Enter invalid email format—should get proper error message.
- Enter invalid phone format (wrong length/type)—should get proper error.
- Provide non-matching passwords (password ≠ confirm password)—should error.
- Submit form without selecting privacy policy checkbox—should block, error message.
C. Usability, UI, Security, Edge Cases
- Verify placeholders are present in all input fields (first name, last name, email, etc.).
- Check that mandatory fields are marked (asterisk or color).
- Password and confirm password fields toggle to hide visibility (input masking).
- Account creation trims leading/trailing spaces from input.
- Password field enforces complexity standards (length, symbol, case; if required by client).
- Verify registration works on all supported environments (OS × Browser matrix).
- Registration form has correct breadcrumb, heading, page title, and URL.
D. Data and Technical Verifications
- Upon registration, all provided details are stored correctly to the database, verified via login or DB query.
E. Navigation
- Access registration page via all possible paths:
- My Account → Register
- Login page → New Customer section → Continue
- Right sidebar links
- Test navigation from registration page to other linked pages (Login, Privacy Policy, menu links).
4. Example Template Mapping (What Each Column Captures)
For each test case, you should record:
Field | Example/Guidance |
---|---|
Test Case ID | Unique, sequential (TC_001, etc.) |
Test Scenario | Reference from previous session (TS_001 for Registration) |
Test Case Title | Brief goal, e.g., “Register with mandatory fields only” |
Pre-requisite | “Open TutorialsNinja application in Chrome” |
Test Steps | Detailed actions (“Click My Account > Register”, "Enter first name", etc.) |
Test Data | User info, email, phone number, etc. (as needed) |
Expected Result | Description of correct outcome—account created, errors shown, data stored etc. |
Actual Result | Leave blank; fill after executing test |
Priority | Usually after bulk authoring, reference from earlier priority (P0–P4) |
Result | Pass/Fail/Blocked |
Client Feedback | After review, for edits or clarifications |
5. Key Principles & Best Practices
- Positive/Negative/Alternate flows: Cover everything users (and hackers) might attempt.
- UI/UX aspects: Placeholders, field markers, accessibility.
- Validation: Server-side and client-side; error messages must be meaningful and consistent.
- Security: Password hiding/complexity, privacy policy enforcement.
- Data: Ensure submitted details truly persist in backend.
- Cross-browser/platform: Must function in all listed environments.
- Coverage Traceability: Each case tied to scenario and requirement (if any).
- Feedback loop: After executing, update Result/Feedback columns; refine cases as per client comments.
6. Typical Test Case Example (Concise View)
Test Case ID: TC_001
Scenario: TS_001 (Registration)
Title: Register account with mandatory fields only
Pre-requisites: Browser open with app URL
Test Steps:
1. Click My Account dropdown menu
2. Select Register option
3. Enter First Name, Last Name, Email, Telephone, Password, Confirm Password
4. Select Privacy Policy checkbox
5. Click Continue
Test Data: New test user data
Expected Result: Account is created, user is logged in, redirected to success page
7. How Many to Write?
- Instructor created 26 detailed test cases for registration—an extensive set for robust testing.
- Adapt and expand based on client requirements, business logic, app complexity, and brainstormed edge scenarios.
8. Session Takeaways
- Creating professional test cases is a mix of practical thinking, thorough coverage, and use of a precise template.
- Always reference your scenario document; maintain traceability, versioning, and review cycles.
- Use both domain knowledge and good judgment; ask client about unclear validation rules and error messages.
- Document everything for later analysis, defect logging, and regression.
Registration Functionality Test Cases Table
Test Case # | Scenario Title/Goal | Steps (Summary) | Expected Result |
---|---|---|---|
001 | Register with only mandatory fields | - Open application- Click "My Account"- Click "Register"- Fill only mandatory fields (firstname, lastname, email, tel, password, confirm, privacy policy)- Click "Continue" | Account createdUser taken to account success pageProper message displayed |
002 | Register with all fields | - Open application- Click "My Account"- Click "Register"- Fill all fields inc. newsletter- Click "Continue" | Account createdUser logged in and taken to account success pageNewsletter subscription reflected |
003 | Submit with no fields filled | - Open application- Click "My Account"- Click "Register"- Leave all fields blank- Click "Continue" | Error/warning messages shown for each mandatory field |
004 | Register with "Yes" for newsletter | - Repeat steps from 002- Select "Yes" for newsletter | Account createdNewsletter status is "subscribed" on account page |
005 | Register with "No" for newsletter | - Repeat steps from 002- Select "No" for newsletter | Account createdNewsletter status is "not subscribed" on account page |
006 | Navigation paths to registration | - Go via "My Account" or Login page, or right options- Click "Register" | User taken to registration page via all valid paths |
007 | Register with non-matching password/confirm | - Fill all details- Enter different values for password and confirm password- Click "Continue" | No account createdError shown for password mismatch |
008 | Register with existing email | - Fill details using already registered email- Click "Continue" | No account createdError: "Email address already exists" |
009 | Invalid email format | - Fill form with invalid email formats (e.g. missing '@' or domain)- Click "Continue" | No account createdError shown on email field |
010 | Invalid phone format | - Enter invalid phone number- Fill rest correctly- Click "Continue" | No account createdError shown on phone field |
011 | Register using keyboard only | - Tab through all fields- Use spacebar for checkbox- Enter/submit | Account creation works without mouse |
012 | Placeholder text in fields | - Inspect field placeholders in registration form | All input fields display correct placeholders inside |
013 | Mandatory fields marked with asterisk | - Inspect registration form | All mandatory fields have red asterisk mark |
014 | Data persistence in DB | - Complete registration- Verify data stored in backend/database | Entered details saved and retrievable in database |
015 | Mandatory fields reject only spaces | - Enter spaces in mandatory fields- Click "Continue" | Error shown, spaces not accepted as valid entries |
016 | Password complexity enforced | - Try weak/simple password variants- Click "Continue" | Error shown, password must meet complexity requirements (length, character variety) |
017 | All fields as per requirements | - Inspect all fields, verify against client requirements (e.g., field length, height, width) | Fields meet UI/UX and business requirements |
018 | Leading/trailing spaces trimmed | - Enter details with spaces at start/end- Click "Continue" | App trims spaces automatically, stores clean data |
019 | Privacy policy checkbox not selected by default | - View registration form | Privacy policy checkbox is off initially; must be manually selected |
020 | Submit without privacy policy | - Fill all fields, don't tick privacy policy- Click "Continue" | Error shown: privacy policy must be accepted |
021 | Password/confirm field text hidden | - Enter password and confirm password- Check visibility | Text in both fields always shown as hidden (dots/stars) |
022 | Navigating to other pages from registration | - Use "Login", "Privacy Policy", etc. links from registration | User navigates correctly to target pages; all links work |
023 | Leave confirm password blank | - Fill all except confirm password- Click "Continue" | Error/warning shown for missing confirm password |
024 | Check page heading/breadcrumb/title/UI | - Inspect UI elements: heading, page title, breadcrumb, URL | All elements are correct and match expectations |
025 | UI checklist (visual aspects, field alignment, etc.) | - General review of UI components | UI follows checklist; proper alignment, colors, sizes |
026 | Registration in all supported browsers/environments | - Repeat registration test across listed environments (Windows, Chrome, Firefox, etc.) | Works in all supported OS/browser combos; no environment-specific defects detected |