Skip to content

Instantly share code, notes, and snippets.

@jdgoettsch
Created February 15, 2019 18:50
Show Gist options
  • Save jdgoettsch/7ea3da19d95fcf1729933464560c5b88 to your computer and use it in GitHub Desktop.
Save jdgoettsch/7ea3da19d95fcf1729933464560c5b88 to your computer and use it in GitHub Desktop.
Selenium example with Firefox and Python 3
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
from selenium import webdriver
def main():
ff = os.path.join('/', 'Applications', 'Firefox Developer Edition.app',
'Contents', 'MacOS', 'firefox')
wd = webdriver.Firefox(firefox_binary=ff)
wd.get('http://are.ucdavis.edu/')
wd.close()
if __name__ == "__main__":
main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment