- name: Clone Red Hat Tempest repo
  git:
    repo="https://github.com/redhat-openstack/tempest.git"
    version='HEAD'
    dest="tempest"

- name: Install pip
  become: yes
  command: "easy_install pip"

- name: Install tempest virtualenv
  shell: python tempest/tools/install_venv.py tempest

- name: Deploy 'venv' script to run tempest related commands inside virtualenv
  copy:
    src="venv"
    dest="tempest/venv"
    mode=0755

- name: Install needed pip packages for running tempest
  become: true
  become_method: sudo
  pip:
    name="{{ item }}"
    state=present
    virtualenv="{{ tempest_venv | default(overcloud_venv) }}"
  with_items:
    - 'junitxml'
    - 'unittest2'

- name: Clone Red Hat Tempest repo
  git:
    repo="https://github.com/redhat-openstack/tempest.git"
    version='HEAD'
    dest="tempest"

- name: Install pip
  become: yes
  command: "easy_install pip"

- name: Install virtualenv
  become: yes
  become_method: sudo
  yum:
    name=python-virtualenv
    state=present

- name: Install tempest virtualenv
  shell: python tempest/tools/install_venv.py tempest

- name: Deploy 'venv' script to run tempest related commands inside virtualenv
  copy:
    src="venv"
    dest="tempest/venv"
    mode=0755

- name: Install needed pip packages for running tempest
  become: true
  become_method: sudo
  pip:
    name="{{ item }}"
    state=present
    virtualenv="{{ tempest_venv | default(overcloud_venv) }}"
  with_items:
    - 'junitxml'
    - 'unittest2'
Add 'virtualenv' to setup_tempest role
Add 'virtualenv' to setup_tempest role

virtualenv is needed to setupthe virtual environment, when we are
installing the packages and running tempest.

Without it installed, you will recieve the follwoing error:
"which: no virtualenv in (/usr/local/bin:/usr/bin)\nPlease
install 'python-virtualenv'".

Change-Id: Id50c6e9c0eebf8d8351ba17e0f8d79812262f811
