There are two web driver managers as shown below,
- If you use this one, you need to do one additional step on the command line, you cannot proceed with the test code unless you execute the below command, as this is part of the webdrivermanager setup.
webdrivermanager -
webdrivermanager 0.7.4
command-line step -
webdrivermanager chrome:2.38 firefox opera:v.2.35
- webdriver-manager 2.3.0
You need to do the following to use webdriver-manager, did you notice something, there is nothing which needs to be done anything specific to webdriver-manager, BEAUTY of making use of robotframework. nice!!!
code
1. pip install webdriver-manager robotframework robotframework-seleniumlibrary
(prjenv) 09:37 PM##~::>pip list
Package Version
------------------------------ ----------
certifi 2018.11.29
chardet 3.0.4
colorama 0.4.1
configparser 4.0.2
crayons 0.3.0
idna 2.8
pip 19.2.3
requests 2.22.0
robotframework 3.1.2
robotframework-seleniumlibrary 4.1.0
selenium 3.141.0
setuptools 40.8.0
urllib3 1.25.6
webdriver-manager 2.2.0
wheel 0.32.3
2. create a file sample.robot
***Settings***
Library SeleniumLibrary
***Test Cases***
Sample Webdriver
[Tags] wd0
[Documentation] Sample invocation using WD
Open Browser http://google.com ff
Close All Browsers
3. execute the file as follows
robot *.robot
Output
========
(prjenv) 09:38 PM##~::>robot *.robot
==============================================================================
Sam
==============================================================================
Sample Webdriver :: Sample invocation using WD | PASS |
------------------------------------------------------------------------------
Sam | PASS |
1 critical test, 1 passed, 0 failed
1 test total, 1 passed, 0 failed
==============================================================================
Output: /Users/apachemain/output.xml
Log: /Users/apachemain/log.html
Report: /Users/apachemain/report.html
THAT'S IT!!!