blob: 120906f98cebe58a3995331632e9a99e37fad048 [file] [log] [blame]
Kailash Khalasid4e05322018-10-01 10:12:40 -07001#!/usr/bin/env bash
2
3# Copyright 2017-present Open Networking Foundation
4#
5# Licensed under the Apache License, Version 2.0 (the "License");
6# you may not use this file except in compliance with the License.
7# You may obtain a copy of the License at
8#
9# http://www.apache.org/licenses/LICENSE-2.0
10#
11# Unless required by applicable law or agreed to in writing, software
12# distributed under the License is distributed on an "AS IS" BASIS,
13# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14# See the License for the specific language governing permissions and
15# limitations under the License.
16
17# setup_venv_lite.sh
18# sets up a python virtualenv for running cord-tester framework tests
19
20WORKSPACE=${WORKSPACE:-.}
21VENVDIR="${WORKSPACE}/venv-cord-tester"
22
23# create venv if it's not yet there
24if [ ! -x "${VENVDIR}/bin/activate" ]; then
25 echo "Setting up dev/test virtualenv in ${VENVDIR} for CORD-TESTER"
26 virtualenv -q "${VENVDIR}" --no-site-packages
27 echo "Virtualenv created."
28fi
29
30echo "Installing python requirements in virtualenv with pip"
31source "${VENVDIR}/bin/activate"
32pip install --upgrade pip
Kailash895244d2019-01-30 09:42:09 -080033pip install cryptography==2.4.2 robotframework robotframework-requests robotframework-sshlibrary \
Scott Baker7b7a2dd2019-02-14 16:25:59 -080034 pexpect robotframework-httplibrary robotframework-kafkalibrary pygments pyyaml \
Andy Bavier88361fb2019-06-10 13:35:18 -070035 robotframework-databaselibrary psycopg2==2.7.7 paramiko==2.4.2
Matteo Scandolo564009f2019-01-16 14:11:02 -080036pip install requests tinydb
Kailash Khalasid4e05322018-10-01 10:12:40 -070037
Scott Baker7b7a2dd2019-02-14 16:25:59 -080038echo "CORD-TESTER virtualenv created. Run 'source ${VENVDIR}/bin/activate'."