If my java code makes a call to any javax.ImageIO method, it throws a silent error. e.g.
File screenshot = ((TakesScreenshot)driver).getScreenshotAs(OutputType.FILE);
try
{
BufferedImage fullImg = ImageIO.read(screenshot);
}
catch(Exception e)
{
e.printStackTrace();
}
no error message is produced, but the code halts at that point. I tried calling ImageIO.getReaderFormatNames() just to see, but it also throws a silent error. This problem occurs in Ubuntu with oracle jre (java version "1.8.0_60") installed. Please note that the same code works perfectly fine in Windows (10). I have tried with FileInputStream as well
FileInputStream fis = new FileInputStream(screenshot);
BufferedImage fullImg = ImageIO.read(fis);