I have the following java method, which successfully creates the png file:
TakesScreenshot scrShot = ((TakesScreenshot) webdriver);
File SrcFile = scrShot.getScreenshotAs(OutputType.FILE);
File DestFile = new File(fileWithPath + featureFileName + ".png");
// BufferedImage img = ImageIO.read(SrcFile);
// ImageIO.write(img, "jpg", new File(fileWithPath + featureFileName + ".jpg"));
FileUtils.copyFile(SrcFile, DestFile);
I'm trying to convert the image to jpg using the 2 commented lines, but jpg
output file is not being produced. No error. No file. I can't figure out why. Thanks in advance for any help.