Skip to content

Commit 5aa8c13

Browse files
committed
test: add artifact-based table selectors test for Automation Lab Tables page
1 parent 2f1bc1f commit 5aa8c13

29 files changed

Lines changed: 1644 additions & 9 deletions

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
node_modules/
33

44
# Playwright test results
5-
playwright-report/
5+
/playwright-report/
66
test-results/
77
allure-results/
88
allure-report/

README.md

Lines changed: 45 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,51 @@
33
<img src="https://playwright.dev/img/playwright-logo.svg" alt="Playwright Logo" height="60" style="margin-right:20px;vertical-align:middle;"/>
44
<img src="artifacts/assets/javascript-logo.svg" alt="JavaScript Logo" height="60" style="margin-right:20px;vertical-align:middle;"/>
55
</p>
6-
7-
8-
9-
# K11TechLab Playwright Automation (JavaScript)
10-
11-
A robust, real-world Playwright automation framework for **K11 Software Solutions**. This project demonstrates best practices in UI automation, advanced reporting, artifact management, and introduces cutting-edge AI-powered test generation for modern web applications.
12-
13-
6+
```
7+
K11TechLab-playwright-javascript-ai-augmented-framework/
8+
9+
├── .env # Environment variables (API keys, etc.)
10+
├── .env.example # Example env file for sharing
11+
├── .gitignore # Git ignore rules
12+
├── .github/ # GitHub workflows & configs
13+
├── ai/ # AI test generator scripts
14+
├── tests/ # All Playwright test suites
15+
│ ├── advanced/ # Visual regression, parallel, network mock
16+
│ │ ├── VisualRegressionTest.spec.js
17+
│ │ ├── ParallelShardTest.spec.js
18+
│ │ └── NetworkMockTest.spec.js
19+
│ ├── api/ # API and integration tests
20+
│ │ ├── AIAPITests.spec.js
21+
│ │ ├── APIActionsIntegration.spec.js
22+
│ │ └── JSONPlaceholderAPITests.spec.js
23+
│ ├── assertions/ # Assertion demos
24+
│ │ └── AssertionBasics.spec.js
25+
│ ├── components/ # Component-level tests (React, UI)
26+
│ │ ├── HeroCarousel.spec.jsx
27+
│ │ ├── QuickActions.spec.jsx
28+
│ │ └── TechLabCard.spec.jsx
29+
│ ├── db/ # DB integration and validation
30+
│ │ ├── FormsLabUIAndDB.spec.js
31+
│ │ └── SampleSQLiteDB.spec.js
32+
│ ├── device/ # Device emulation tests
33+
│ │ └── DeviceHomeTest.spec.js
34+
│ ├── e2e/ # End-to-end flows
35+
│ │ └── E2ELoginDashboardTest.spec.js
36+
│ ├── mcp/ # Model Context Protocol scenarios
37+
│ │ └── MCPLoginTest.spec.js
38+
│ ├── navigators/ # Navigation strategies
39+
│ │ ├── NavigatorBasics.spec.js
40+
│ │ └── NavigatorAdvanced.spec.js
41+
│ ├── selectors/ # Selector strategies (basic, advanced, shadow DOM, iframe)
42+
│ │ ├── SelectorBasics.spec.js
43+
│ │ └── SelectorsAdvanced.spec.js
44+
│ ├── smoke/ # Smoke and regression flows
45+
│ │ ├── HelloWorld.spec.js
46+
│ │ ├── HomeTest.spec.js
47+
│ │ ├── LoginTest.spec.js
48+
│ │ └── FormsLabTest.spec.js
49+
│ └── sync/ # Synchronization and waits
50+
│ └── SynchronizationTechniques.spec.js
1451
## 🚀 Capabilities & Innovations
1552
1653
- **Playwright basic to advanced learning path:** Step-by-step demo tests and documentation guide you from Playwright fundamentals to advanced automation. Explore real-world scenarios on K11softwaresolutions.com, with code in the `tests/` directory and detailed articles in `/doc`.

k11techlab.md

Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
# K11TechLab Overview
2+
3+
## Locators Lab ([https://k11softwaresolutions.com/labs/locators](https://k11softwaresolutions.com/labs/locators))
4+
5+
The Locators Lab is a dedicated playground for mastering Playwright selector strategies. It features intentionally complex and varied UI patterns, allowing you to practice and validate:
6+
- Text, CSS, XPath, nth, attribute, role, label, and test id selectors
7+
- Shadow DOM and iframe element targeting
8+
- Deep search and advanced locator scenarios
9+
10+
### Key Sections
11+
- **Sandbox Area**: Contains all practice elements and sections.
12+
- **Dummy Form**: Includes multiple input fields, disabled fields, and a submit button for form automation.
13+
- **User Table**: Practice table row and cell selection.
14+
- **Shadow DOM**: Elements inside open shadow roots for deep selector practice.
15+
- **Popups & Actions**: Buttons to trigger alerts, prompts, modals, and file downloads.
16+
- **iframe Lab (srcDoc)**: Embedded iframe with its own form, table, and note for cross-frame automation.
17+
18+
## Form Elements in Locators Lab
19+
20+
The Dummy Form section provides a variety of form elements:
21+
- **User Email**: `<input id="userEmail" type="email">`
22+
- **Password**: `<input id="userPass" type="password">`
23+
- **Company Name**: `<input id="companyName" type="text">`
24+
- **Mobile**: `<input id="mobile" type="tel">`
25+
- **Country**: `<input id="country" type="text">`
26+
- **Disabled Name**: `<input id="disabledName" type="text" disabled>` (can be enabled)
27+
- **Submit Button**: `<button id="locators-lab-run-btn">Submit</button>`
28+
29+
These elements are ideal for:
30+
- Practicing input, fill, and validation actions
31+
- Testing attribute-based and role-based selectors
32+
- Demonstrating form automation and error handling
33+
34+
35+
## Labs Forms Page ([https://k11softwaresolutions.com/labs/forms](https://k11softwaresolutions.com/labs/forms))
36+
37+
The Labs Forms page (`/labs/forms`) is a dedicated area for practicing form automation, validation, and error handling. It includes:
38+
- Multiple input fields (email, password, company, etc.)
39+
- Form validation scenarios
40+
- Disabled/enabled fields
41+
- Submit and reset buttons
42+
43+
This page is ideal for:
44+
- Focused form automation and validation tests
45+
- Demonstrating error handling and edge cases
46+
- Practicing attribute-based and role-based selectors
47+
48+
Use a dedicated page object for Labs Forms if you want maintainable selectors and robust test coverage.
49+
50+
51+
52+
## Automation Lab Tables Page ([https://k11softwaresolutions.com/automation-lab/tables](https://k11softwaresolutions.com/automation-lab/tables))
53+
54+
The Automation Lab Tables page is designed for practicing advanced table selectors and automation. It includes:
55+
- Multiple tables with varied structures and attributes
56+
- Demo table with headers, rows, and cells for selector practice
57+
- Cells with custom attributes (e.g., `data-status`)
58+
- Realistic data for row/cell selection
59+
60+
This page is ideal for:
61+
- Practicing text, CSS, XPath, nth, attribute, role, and partial text selectors on tables
62+
- Validating table automation scenarios (row/cell selection, header targeting)
63+
- Demonstrating robust selector strategies for tabular data
64+
65+
Refer to SelectorsAdvanced.spec.js for comprehensive table selector demos.
66+
67+
---
68+
69+
70+
## Usage
71+
- Use the LocatorsLabPage page object for robust, maintainable selectors.
72+
- Refer to SelectorsAdvanced.spec.js for comprehensive selector demos.
73+
- Explore advanced scenarios like shadow DOM and iframe element targeting.
74+
- Use Labs Forms page for focused form automation and validation.
75+
76+
---
77+
For more details, see:
78+
- [doc/playwright-basics/advanced-selectors.md](doc/playwright-basics/advanced-selectors.md)
79+
- [tests/selectors/SelectorsAdvanced.spec.js](tests/selectors/SelectorsAdvanced.spec.js)
80+
- [pages/LocatorsLabPage.js](pages/LocatorsLabPage.js)

reports/E2ELoginDashboardTest/playwright-report/index.html

Lines changed: 85 additions & 0 deletions
Large diffs are not rendered by default.

reports/FormsLabUIAndDB/playwright-report/index.html

Lines changed: 85 additions & 0 deletions
Large diffs are not rendered by default.
86.9 KB
Loading
Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
1+
# Page snapshot
2+
3+
```yaml
4+
- generic [ref=e1]:
5+
- banner [ref=e2]:
6+
- generic [ref=e3]:
7+
- link "K11 Logo K11 Software Solutions" [ref=e4]:
8+
- /url: /
9+
- img "K11 Logo" [ref=e5]
10+
- generic [ref=e6]: K11 Software Solutions
11+
- link "Register" [ref=e8]:
12+
- /url: /register
13+
- generic [ref=e9]:
14+
- heading "Login" [level=2] [ref=e10]
15+
- generic [ref=e11]:
16+
- textbox "Email or Username" [active] [ref=e12]
17+
- textbox "Password" [ref=e13]: testpass
18+
- link "Forgot your password?" [ref=e15]:
19+
- /url: /forgot-password
20+
- button "Log In" [ref=e16] [cursor=pointer]
21+
- paragraph [ref=e17]:
22+
- text: Don’t have an account?
23+
- link "Register here" [ref=e18]:
24+
- /url: /register
25+
- contentinfo [ref=e19]:
26+
- generic [ref=e20]:
27+
- generic [ref=e22]:
28+
- generic [ref=e23]:
29+
- img "K11 Logo" [ref=e24]
30+
- generic [ref=e25]: K11 Software Solutions
31+
- generic [ref=e26]: AI & Automation Experts
32+
- paragraph [ref=e27]:
33+
- text: Transforming ideas into intelligent software.
34+
- text: Consulting, Automation, and AI-enabled application development.
35+
- generic [ref=e28]:
36+
- generic [ref=e29]:
37+
- heading "Solutions" [level=3] [ref=e30]
38+
- list [ref=e31]:
39+
- listitem [ref=e32]:
40+
- link "Services" [ref=e33]:
41+
- /url: /services
42+
- listitem [ref=e34]:
43+
- link "Insights" [ref=e35]:
44+
- /url: /insights
45+
- listitem [ref=e36]:
46+
- link "Community" [ref=e37]:
47+
- /url: /community
48+
- listitem [ref=e38]:
49+
- link "About" [ref=e39]:
50+
- /url: /about
51+
- listitem [ref=e40]:
52+
- link "Contact" [ref=e41]:
53+
- /url: /contact
54+
- generic [ref=e42]:
55+
- heading "Contact & Trust" [level=3] [ref=e43]
56+
- list [ref=e44]:
57+
- listitem [ref=e45]:
58+
- link "k11softwaresolutions@gmail.com" [ref=e46]:
59+
- /url: mailto:k11softwaresolutions@gmail.com
60+
- listitem [ref=e47]: US / Remote
61+
- listitem [ref=e48]: NDA-friendly
62+
- listitem [ref=e49]: 24–48h response
63+
- generic [ref=e50]:
64+
- heading "Get Started" [level=3] [ref=e51]
65+
- list [ref=e52]:
66+
- listitem [ref=e53]:
67+
- link "Explore Services" [ref=e54]:
68+
- /url: /services
69+
- listitem [ref=e55]:
70+
- link "Subscribe" [ref=e56]:
71+
- /url: /register
72+
- generic [ref=e58]:
73+
- generic [ref=e59]: "Follow Me:"
74+
- link "LinkedIn" [ref=e60]:
75+
- /url: https://www.linkedin.com/company/k11-software-solutions/
76+
- text: "|"
77+
- link "GitHub" [ref=e61]:
78+
- /url: https://github.com/K11-Software-Solutions
79+
- text: "|"
80+
- link "YouTube" [ref=e62]:
81+
- /url: https://www.youtube.com/@k11-tech/
82+
- generic [ref=e63]:
83+
- generic [ref=e64]: © 2025 K11 Software Solutions
84+
- generic [ref=e65]:
85+
- link "Privacy" [ref=e66]:
86+
- /url: /privacy-policy
87+
- text: "|"
88+
- link "Terms" [ref=e67]:
89+
- /url: /terms-of-use
90+
- text: "|"
91+
- link "Contact" [ref=e68]:
92+
- /url: /contact
93+
- alert [ref=e69]
94+
```
Binary file not shown.

reports/NavigatorAdvanced/playwright-report/index.html

Lines changed: 85 additions & 0 deletions
Large diffs are not rendered by default.

reports/SelectorsAdvanced/playwright-report/index.html

Lines changed: 85 additions & 0 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)