A Selenium / Java / TestNG / Maven test automation framework built with Page Object Model (POM) architecture, data-driven test support via Excel utilities, and modular reporting.
| Pattern | Implementation |
|---|---|
| Page Object Model | Page classes in src/main/java/pages — UI interactions separated from test logic |
| Utility layer | src/main/java/utils — reusable helpers including Excel data reader |
| Data-driven testing | Test data loaded from Excel via utility class — tests run across multiple data sets without code changes |
| TestNG suite config | testng.xml — controls test grouping, parallel execution, and suite-level setup |
| Maven standard layout | Standard src/main/java + src/test/java structure — builds and runs with a single mvn test |
| Modular reporting | Test output in test-output/ — TestNG HTML reports generated on every run |
TAU_WebdriverJava/
│
├── src/
│ ├── main/java/
│ │ ├── pages/ # Page Object classes — one class per page/component
│ │ └── utils/ # Utility helpers — Excel reader, waits, common actions
│ │
│ └── test/
│ ├── java/ # Test classes — TestNG @Test methods
│ └── resources/ # Test data files, config properties
│
├── test-output/ # TestNG HTML reports (generated — not committed)
├── pom.xml # Maven dependencies and plugin config
└── testng.xml # TestNG suite — groups, parallel config, listeners
- Selenium WebDriver 4 — browser automation
- Java 11+ — test language
- TestNG — test runner, assertions, grouping, parallel execution
- Maven — build and dependency management
- Apache POI — Excel file reading for data-driven tests
- Page Object Model — separation of page UI interactions from test logic
- Java 11 or higher
- Maven 3.6+
- Chrome browser + matching ChromeDriver (or use WebDriverManager)
mvn testmvn test -DsuiteXmlFile=testng.xmlmvn test -Dgroups=smokeWhy Page Object Model? Separating page-level UI interactions (locators, actions) from test logic means a single UI change is fixed in one place — the page class — not across every test that touches that element.
Why Excel for test data? Non-technical stakeholders can own and update test data without touching code. Data-driven tests run the same scenario across multiple input rows, increasing coverage without duplicating test methods.
Why TestNG over JUnit?
TestNG's testng.xml gives explicit control over suite composition, test grouping, parallel thread configuration, and listener injection — essential for a maintainable regression suite.
For my current C# / ReqNRoll framework (production-style BDD with hooks, CI/CD, and AI-assisted PR review), see: reqnroll-bdd-framework
Ashish Shilvant — Specialist Test Automation Engineer
LinkedIn · GitHub