Test Environment:
Dependencies:
| Field | Description | Example Value |
|---|---|---|
| Test URL | Application homepage | https://www.automationexercise.com |
| Navigation Links | Menu items to validate | Home, Products, Cart, Signup / Login, Test Cases, API Testing, Video Tutorials, Contact Us |
| Step # | Action | Locator / Reference | Expected Result |
|---|---|---|---|
| 1 | Navigate to homepage | ul.nav.navbar-nav |
Homepage loads; navigation menu is visible. |
| 2 | Verify navigation link count | ul.nav.navbar-nav > li |
Exactly 8 links are displayed in correct order. |
| 3 | Click Home link | ul.nav.navbar-nav > li > a[href="/"] |
User remains on homepage (/); sections like Featured Items and Recommended Items visible. |
| 4 | Click Products link | ul.nav.navbar-nav > li > a[href="/products"] |
Redirects to /products; product grid loads with items, names, prices. |
| 5 | Click Cart link | ul.nav.navbar-nav > li > a[href="/view_cart"] |
Redirects to /view_cart; cart table and totals visible. |
| 6 | Click Signup / Login link | ul.nav.navbar-nav > li > a[href="/login"] |
Redirects to /login; email and password fields visible. |
| 7 | Click Test Cases link | ul.nav.navbar-nav > li > a[href="/test_cases"] |
Redirects to /test_cases; list of test cases visible. |
| 8 | Click API Testing link | ul.nav.navbar-nav > li > a[href="/api_list"] |
Redirects to /api_list; API endpoint list visible. |
| 9 | Click Video Tutorials link | ul.nav.navbar-nav > li > a[href="https://www.youtube.com/c/AutomationExercise"] |
Opens YouTube channel in new tab, validated in separate automation script. |
| 10 | Click Contact Us link | ul.nav.navbar-nav > li > a[href="/contact_us"] |
Redirects to /contact_us; form with fields Name, Email, Subject, Message, Submit visible. |
(To be filled after execution.)
test_tc_ui_nav_001.py and test_tc_ui_nav_001_video_tutorials.pypage.url() and expect(page).to_have_url() assertions.| Element | Purpose | Playwright Locator |
|---|---|---|
| Navigation bar | Container for all menu items | ul.nav.navbar-nav |
| Home link | Homepage redirect | a[href="/"] |
| Products link | Product listing page | a[href="/products"] |
| Cart link | Cart page | a[href="/view_cart"] |
| Signup / Login link | Login/registration page | a[href="/login"] |
| Test Cases link | Test case list | a[href="/test_cases"] |
| API Testing link | API list page | a[href="/api_list"] |
| Video Tutorials link | YouTube channel | a[href*="youtube.com"] |
| Contact Us link | Contact form page | a[href="/contact_us"] |