Accept the cookie consent banner
Easy25 pts
- Overlays
- Visibility
- 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
A cookie banner covers the bottom of the page on first visit. Accept all cookies and verify the banner is gone and the preference is recorded.
Your Task
- 1Open TEST_URL and wait for the cookie banner (#cookie-banner).
- 2Click “Accept all” (#accept-cookies).
- 3Assert the banner is no longer visible.
- 4Assert the footer #consent-state reads “Cookie preference: accepted”.
Validation Checks
- The cookie banner is closed.
- The footer records the accepted preference.
- The test asserts the banner closed.
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 Easy Selenium Challenges exercise runs inside TargetQA's managed cloud sandbox using Selenium WebDriver 4 (Java, Python, 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: Java (Selenium 4 + JUnit 5) · Python (Selenium 4 + pytest) · C# (Selenium 4 + 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 3 acceptance checks and earn 25 points.
Selenium WebDriver 4 · Selenium Challenges Practice Track · ShopZone