Friday, May 20, 2016

Install Robot FrameWork on Ubuntu 14.04




So, let's get started with the installation.

1. PYTHON

Python is bundled with the Ubuntu/Linux installation.

To check if it's installed, and the installed version of Python on your system, 

enter the below command in terminal (shortcut key for terminal: Ctrl+Alt+T)
$ python --version

If Python is installed, you should see something like below as the output:

Python 2.7.3

Note that - Robot Framework is not yet supported on Python 3. You must have 

Python 2.5.X (or higher) version installed (in order to install Robot Framework 

2.5 or higher)

If you need to upgrade your Python (say from 2.7.3 to 2.7.6), check out the 

below link:
http://askubuntu.com/questions/443048/python-2-7-6-on-ubuntu-12-04-how-to


2. PIP (Python Package Manager)

easy_install and pip are package managers for installing Python packages. 

Using pip is recommended as it's more advanced and has good uninstallation 

support.

To install
pip, run the below commands:


$ wget https://bootstrap.pypa.io/get-pip.py
 
$ sudo python get-pip.py



3. ROBOT FRAMEWORK

Install Robot Framework package using
pip
:

$ sudo pip install robotframework

This will install the latest version of Robot Framework. If you have a need to 

install a specific version, mention the version as below (replace 2.8.4 with your 

desired version):

$ sudo pip install robotframework==2.8.4

Once the installation completes, to verify if the installation went OK, enter the 

below command:

$ pybot --version

If the setup was successful, you should see something like below as its output:

Robot Framework 2.8.4 (Python 2.7.3 on linux2)

4. SELENIUM2LIBRARY : Robot Framework's Test Library for Webdriver tool

In order to work with Webdriver (Selenium 2) and Robot Framework, you need 

to install 'Selenium2Library'. You can perform the pip installation as below:

$ sudo pip install robotframework-selenium2library

This will automatically install its dependencies (decorator, selenium packages). 

Once the installation completes, to verify if the installation went OK, enter the 

below commands:
$ python

This starts the Python interpreter. Now, enter the below statement:

>> import Selenium2Library

There wouldn't be any output :). No error indicates that the library was installed 

successfully. You can exit the Python interpreter using exit() command.

5. RIDE : Robot Framework Integrated Development Environment

RIDE is an IDE for test development using Robot Framework.

As RIDE is developed using wxPython, you need to install wxPython 2.8 toolkit 

with unicode support to run RIDE. Unfortunately, pip cannot be used to install 

wxPython (as setup.py doesn't exist for wxPython). Run the below commands to 

install wxPython:
$ sudo apt-get install python-wxgtk2.8
 
$ sudo apt-get install python-wxversion

Now, you can perform the
pip installation for RIDE as below:

$ sudo pip install robotframework-ride 

To  verify if the installation went OK, run the below command:

$ ride.py

You should see the RIDE application GUI:

Congratulations! You are all set to develop your automated tests on your Ubuntu/Linux system using Robot Framework and Selenium2Library in the RIDE editor !!

Thanks & Regards,


Bhargava Batchu.

2 comments:

Update GitLab (Omnibus based installations)

Welcome To My Blog Cash Back Shopping. Get Deals & Save Money Shop AT Ebates Try for Free!!!!                                      ...