Validate the registration form errors
Medium50 pts
- Form validation
- Field errors
- Multiple assertions
Practice app · ShopZone
A full marketplace: two-step sign-in, search with filters and sorting, product pages with tabs, a cart with coupons, and checkout.
Your starter code already declares TEST_URL — never hardcode a host.
Objective
Submit the Create account form with invalid data and verify every field-level validation message.
Your Task
- 1Open TEST_URL, go to sign-in and click “Create your ShopZone account” (#create-account).
- 2Fill #reg-name with “Ravi Kumar”, #reg-email with “ravi.kumar” (no domain), #reg-password with “short” and #reg-confirm with “different”.
- 3Click #reg-submit.
- 4Assert #reg-email-error, #reg-password-error and #reg-confirm-error show the expected messages, and that #reg-name-error is not shown.
Validation Checks
- The email error says “Enter a valid email address”.
- The password error mentions the 8-character minimum.
- The confirmation error says the passwords must match.
- The test makes at least three assertions.
Fixtures
- buyer@shopzone.test
- Password
- Shop@123
- Account name
- Asha Verma
- Coupon
- SAVE10 (10% off the subtotal)
- Pincodes
- 560001 Bengaluru · 110001 New Delhi · 400001 Mumbai · 600001 Chennai
Cloud Execution & Grading Guide
This Medium Playwright Challenges exercise runs inside TargetQA's managed cloud sandbox using Playwright (TypeScript, JavaScript, Python, Java, C#). Every submission runs inside an isolated headless Chromium container with pre-synced drivers, capturing live console logs, DOM assertions, and a 720p step-by-step video replay.
- Supported stacks: TypeScript (@playwright/test) · JavaScript (@playwright/test) · Python (Playwright + pytest) · Java (Playwright for Java + JUnit 5) · C# (Playwright for .NET + NUnit)
- Zero local setup: Use the pre-declared
TEST_URLvariable so your script targets the live ShopZone sandbox reliably without hardcoding hosts. - Automated grading: Click Run to inspect step logs and behavior, then click Submit to validate all 4 acceptance checks and earn 50 points.
Playwright · Playwright Challenges Practice Track · ShopZone