Using Robot Framework on CentOS 7

Overview

The Robot Framework is a generic test automation framework. When you're getting started with Robot Framework, please go through Robot Framework User Guide at least once, and you will benefit from the user guide.

Robot Framework provides a graphical user interface called RIDE (Robot Integrated Development Environment) that can help a lot in writing and managing testcases and keywords written in Resource Files.

Precondition

If you’re familiar with Python packaging and installation, and just want to know what tools are currently recommended, then here it is.

sudo yum install -y python-pip
sudo pip install --upgrade pip

It is recommended to use virtualenv as a development Python environment that robot framework implemented using.

sudo pip install virtualenv virtualenvwrapper

Setup an isolate workspace by virtualenvwrapper.

export WORKON_HOME=~/python_projects
mkdir -p $WORKON_HOME
source `which virtualenvwrapper.sh`
mkvirtualenv --no-site-packages robotframework
  1. --no-site-packages: Don't give access to the global site-packages dir to the virtual environment (default)
  2. To tell pip to only run if there is a virtualenv currently activated, and to bail if not, use: export PIP_REQUIRE_VIRTUALENV=true
  3. To tell pip to automatically use the currently active virtualenv: export PIP_RESPECT_VIRTUALENV=true

Switch between environments with workon:

workon robotframework

Installation

Just run the following commands to clone RIDE's repository and start the latest version:

cd $WORKON_HOME/robotframework
git clone https://github.com/robotframework/RIDE.git
cd RIDE

Necessary development dependencies can be installed with:

sudo pip install -r requirements.txt

Reference:
https://blog.codecentric.de/en/2012/03/robot-framework-tutorial-overview/

results matching ""

    No results matching ""