Skip to content

Instantly share code, notes, and snippets.

@007bsd
Created November 30, 2017 13:44
Show Gist options
  • Select an option

  • Save 007bsd/979a4d91f8d2d4de4ac4ef88e15821ba to your computer and use it in GitHub Desktop.

Select an option

Save 007bsd/979a4d91f8d2d4de4ac4ef88e15821ba to your computer and use it in GitHub Desktop.
Capturing Large Screen Shot In Robot Framework
def capture_large_screenshot():
currentWindow = s2l.get_window_size()
page_height = s2l._current_browser().execute_script("return typeof(jQuery) !== 'undefined' ? jQuery(document).height() : 1080;")
page_width = currentWindow[0]
original_height = currentWindow[1]
s2l.set_window_size(page_width, page_height)
s2l.capture_page_screenshot()
s2l.set_window_size(page_width, original_height)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment