Selenium4: Full page screenshot
1 min readNov 29, 2019
Full page screenshot — Using Selenium 4 (alpha 2 or greater), now we can take the full page screenshots with getFullPageScreenshotAs() method in the Firefox. But instead of typecasting it to ‘TakesScreenshot’ interface, we need to typecast it to FirefoxDriver instance.
File src = ((FirefoxDriver) driver).getFullPageScreenshotAs(OutputType.FILE);