I am using complex selenium tests and pyvirtualdisplay in order to take screenshots during the selenium testing. However, I am using the following code to create a Display:
self.display = Display(visible=0, size=(1366, 768))
self.display.start()
and something like this code
self.driver.save_screenshot(savename)
to create a screenshot (where self.driver is a selenium-webdriver). However, the screenshots I get are much smaller that defined, like 911x197 pixels. Do I have to make some special configurations to get a better screenshot? So far I only can see small parts of the headless browser I am using for testing...
Do you start your browser with "--start-maximized" option?