Setup
This tutorials will be based around easyselenium.
easyselenium is simple Selenium WebDiver wrapper written in Python.
Why? - It has GUI.
Tutorial will be done in Windows OS but all software can be use on MacOS and GNU/Linux as well.
Needed software:
- Install Python 2.7 - https://www.python.org/downloads/
- NOTE: Select 'Add python.exec to Path' during installation process
- Install pip - https://pip.pypa.io/en/stable/installing/
- Download and execute https://bootstrap.pypa.io/get-pip.py
- Install wxPython - http://wiki.wxpython.org/How%20to%20install%20wxPython
- Download and install correct version for Python 2.7 and your OS(32 or 64 bit) http://www.wxpython.org/download.php#msw
- Install Selenium WebDriver with pip - open command promt('cmd.exe') and run command: pip install selenium
- Install nose with pip - open command promt('cmd.exe') and run command: pip install nose
- Install nose-htmloutput plug-in with pip - Open command promt('cmd.exe') and run command: pip install nose-htmloutput
- Install nose-pathmunge plug-in with pip - Open command promt('cmd.exe') and run command: pip install nose-pathmunge
- Install easyselenium
- Download and extract archive https://github.com/kirillstrelkov/easyselenium/archive/master.zip
- Go to easyselenium-master\easyselenium-master folder
- Open command promt('cmd.exe') and go to folder where setup.py script is located(use 'cd' command), example:
- cd C:\Users\IE User\Downloads\easyselenium-master\easyselenium-master\
- Run installation script in command promt:
- setup.py install
- Install Chrome browser - https://www.google.com/chrome/
- Install Git
- Download and install https://git-scm.com/downloads
- Download Jenkins
- Download LTS version https://jenkins.io/index.html
- Install ChromeDriver
- Download&extract latest driver https://sites.google.com/a/chromium.org/chromedriver/downloads
- Move it to home folder(ex. C:\Users\IE User)
- Install Internet Explorer Driver Server
- Go to http://www.seleniumhq.org/download/
- Find header 'The Internet Explorer Driver Server'
- Download&extract latest correct version
- Move it to home folder(ex. C:\Users\IE User)
Check that everything works:
- Close all opened command promts and open new one
- Execute command: easy_selenium_ui.py
- You should see something like that see 'Easy selenium UI' picture
- Choose 'gc' - google chrome as a browser
- Try to open browser by clicking 'Open url'
- You should see new Google Chrome window
- Try to close browser by clicking 'Close browser'
- Google Chrome window should be closed
Easy selenium UI |
Next: Test case creation
Nice blog..! I really loved reading through this article. Thanks for sharing.You done a great job.Dell Boomi Training in Bangalore
ReplyDelete