Fix BenchmarkRunner to only import selenium when needed
[WebKit-https.git] / Tools / Scripts / webkitpy / benchmark_runner / browser_driver / osx_safari_driver.py
index 89a2f06d4971d8561ad5d9524e3470d856aa1f93..c6a0c4a3f78f5161ba33b546ff2dce9d2dce1da6 100644 (file)
@@ -7,7 +7,6 @@ import time
 
 from osx_browser_driver import OSXBrowserDriver
 from webkitpy.benchmark_runner.utils import force_remove
-from selenium import webdriver
 
 
 _log = logging.getLogger(__name__)
@@ -46,6 +45,7 @@ class OSXSafariDriver(OSXBrowserDriver):
         subprocess.Popen(['open', '-a', args[0], url])
 
     def launch_driver(self, url, options, browser_build_path):
+        from webkitpy.thirdparty.autoinstalled.selenium import webdriver
         driver = webdriver.Safari(quiet=False)
         self._launch_webdriver(url=url, driver=driver)
         return driver