public void grabScreenShot() throws IOException{
System.out.println("in grap screen shot method"); // till here it will work
File screenShotFile = ((TakesScreenshot) drive).getScreenshotAs(OutputType.FILE);
FileUtils.copyFile(screenShotFile, new File("D:\\screenShot.jpeg"));
System.out.println("Screen shot is taken");
}
public void getScreenShot() throws IOException{
System.out.println("x"); // till here it will work
EventFiringWebDriver edrive= new EventFiringWebDriver(drive);
File srcImgFile = edrive.getScreenshotAs(OutputType.FILE);
System.out.println("y");
File dstImgFile = new File("D:/Study/Selenium practices/HybridFramework/src/screenShot/screenShot.jpeg");
FileUtils.copyFile(srcImgFile, dstImgFile);
System.out.println("z");
}