Professional Documents
Culture Documents
Framework - Explain
1. Config - url, uname and pwd, browser, role, etc
2. What are Listeners ? Are you using it in your framework ?
3. Reporting mechanisms (TestNg, Allure, Extent)
4. BDD ? (At least basic knowledge)
5. Have you used Interface in your framework ?
6. DDT - Reading Data from Excel
Solutions
1. findElement
String locator = By.xpath(“//div[@id=’test’]”);
WebElement element = driver.findElement(locator);
2. Actions Click
Actions act = new Actions(driver);
String locator = By.xpath(“//div[@id=’test’]”);
act.click(locator).perform();
try {
FileUtils.copyFile(screenshot, new File("C:\\
projectScreenshots\\homePageScreenshot.png"));
} catch (IOException e) {
System.out.println(e.getMessage());
}
Workbook wb = WorkbookFactory.create(fis);
Sheet s = wb.getSheet(“sheetName”);