Skip to content

Instantly share code, notes, and snippets.

@bmannix
Last active December 19, 2015 03:08
Show Gist options
  • Save bmannix/5887489 to your computer and use it in GitHub Desktop.
Save bmannix/5887489 to your computer and use it in GitHub Desktop.
get Selenium version used by Selenium2Library and log it
from robot.libraries.BuiltIn import BuiltIn
from robot.api import logger
def log_s2l_version():
"""
Gets the Selenium version used by Selenium2Library
"""
seleniumlib = BuiltIn().get_library_instance('Selenium2Library')
browser = seleniumlib._current_browser()
sel_version = locals()['webdriver'].__version__
logger.info('Selenium Version is: %s' % sel_version)
return
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment