Selenium + TestNG automation framework for the Calley Team Account Setup flow on app.getcalley.com, built using the Page Object Model (POM) design pattern with Java and Maven.
This project automates four core user journeys:
- User Registration (including WhatsApp OTP verification and free trial plan activation)
- User Login
- Add Agent
- CSV Upload via Power Import
| Tool | Purpose |
|---|---|
| Java | Programming language |
| Selenium WebDriver | Browser automation |
| TestNG | Test framework & assertions |
| Maven | Build & dependency management |
| WebDriverManager | Auto-manages ChromeDriver binaries |
| Page Object Model (POM) | Design pattern for maintainable test code |
Calley_Team/
├── src/
│ ├── main/
│ │ ├── java/
│ │ │ ├── BaseClass.java # WebDriver setup/teardown, loads config
│ │ │ └── pompages/
│ │ │ ├── RegistrationPage.java # Registration, OTP verification, plan selection
│ │ │ ├── LoginPage.java # Login + popup dismissal
│ │ │ ├── AgentPage.java # Add Agent flow
│ │ │ ├── CSVUploadPage.java # Call List > Power Import
│ │ │ └── DashboardPage.java # Post-login dashboard checks
│ │ └── resources/
│ │ ├── data.properties # URLs, credentials, test data (data-driven)
│ │ └── sample_leads.csv # Sample CSV for Power Import testing
│ └── test/
│ └── java/
│ ├── RegistrationTest.java # End-to-end registration test
│ └── FullSetupTest.java # Login -> Add Agent -> CSV Upload (ordered)
├── pom.xml
├── testng.xml
└── README.md
- Java JDK 8+
- Maven
- Google Chrome installed
- Eclipse (or any Java IDE) with the TestNG plugin
- Clone the repository:
git clone https://github.com/Rahulchandeshware/Calley-Teams-Automation.git
- Open the project in Eclipse as a Maven project.
- Update
src/main/resources/data.propertieswith valid test credentials (see Configuration below). - Run
mvn clean installto pull dependencies.
- Right-click
testng.xml→ Run As → TestNG Suite, or - Run via Maven:
mvn test
All test data and URLs live in data.properties — nothing is hardcoded in the Java classes:
registration.url=https://app.getcalley.com/registration.aspx
login.url=https://app.getcalley.com/Login.aspx
reg.fullName=Your Name
reg.email=your.real.email@example.com
reg.whatsapp=<a real WhatsApp-enabled number>
reg.password=YourPassword123
login.email=<email of an account that completed registration>
login.password=YourPassword123
agent.name=Test Agent
agent.mobile=9123456780
agent.email=testagent@example.com
agent.password=Agent@12345
agent.lead=
csv.listName=AutomationTestList
csv.filePath=src/main/resources/sample_leads.csvNote:
reg.whatsappmust be a real, WhatsApp-enabled number, since Calley sends an actual OTP to it during registration (see Known Limitations below).
Two steps in this flow cannot be fully automated and require manual interaction during the test run, by design — not as a framework gap:
| Step | Why it can't be automated |
|---|---|
| reCAPTCHA ("I'm not a robot") | Google's reCAPTCHA is specifically built to detect and block automated/Selenium-driven browsers. The framework pauses execution (waitForManualRecaptcha()) so a human can click it manually. |
| WhatsApp OTP verification | The OTP is sent to a real WhatsApp number and has no programmatic API access. The framework pauses (waitForManualOtpEntry()) so a human can read the message and enter the code. |
Both are the industry-standard workaround for automating flows with 2FA/CAPTCHA — pausing for manual input rather than attempting to bypass security controls.
- Page Object Model: each screen (Registration, Login, Agent, CSV Upload) has its own class containing only locators + actions. Test classes never reference a
Bylocator directly. - Popup handling: several SweetAlert/Bootstrap popups (OTP-sent alert, "Agent Added Successfully", "Are you sure?" Power Import confirmation, app-install promo, notification subscription prompt) are dismissed automatically within page methods, so they never block subsequent test steps.
- Data-driven: all test data lives in
data.properties, keeping test logic and test data cleanly separated. - Independent tests: each
@Testmethod gets a fresh browser session viaBaseClass's@BeforeMethod/@AfterMethod, trading a little speed for easier debugging when a single step fails.
Rahul Chandeshware