Skip to content

Instantly share code, notes, and snippets.

@gerhardqux
Created October 13, 2019 07:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gerhardqux/057ec267e5bb02c4d85d10e6bc9d8799 to your computer and use it in GitHub Desktop.
Save gerhardqux/057ec267e5bb02c4d85d10e6bc9d8799 to your computer and use it in GitHub Desktop.
#!/usr/bin/env python3
from selenium import webdriver
driver = webdriver.Firefox()
driver.get("http://www.qux.nl")
print(driver.title)
driver.save_screenshot("qux.png")
driver.close()
driver = webdriver.Chrome()
driver.get("https://www.qrux.nl")
print(driver.title)
driver.save_screenshot("qrux.png")
driver.get("http://www.qux.nl")
print(driver.title)
driver.save_screenshot("qux.png")
driver.close()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment