Bug 873: Robot Automation improvement to install chrome driver only for gui test
Change-Id: If11bbb9a2f8e0b011fcdc3d16d7a6b72a035343f
Signed-off-by: yadavmr <my00514913@techmahindra.com>
diff --git a/robot-systest/run_test.sh b/robot-systest/run_test.sh
index 74f8aa1..42b2328 100644
--- a/robot-systest/run_test.sh
+++ b/robot-systest/run_test.sh
@@ -32,11 +32,6 @@
echo -e "\nInstalling robot requirements"
# installing python packages
pip install haikunator requests robotframework robotframework-seleniumlibrary robotframework-requests
-
- # installing chrome driver and chrome for UI testing
- curl -sS -o - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add -
- echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list
- apt-get update && apt-get -y install google-chrome-stable chromium-chromedriver
}
while getopts ":t:-:" o; do
@@ -65,7 +60,7 @@
exit 0
elif [[ "$TEST" == "smoke" ]]; then
echo "Robot Framework SMOKE test"
- robot -d $BASEDIR/reports -i smoke $BASEDIR/testsuite/
+ robot --removekeywords tag:vim-setup --removekeywords WUKS -d $BASEDIR/reports -i smoke $BASEDIR/testsuite/
exit 0
elif [[ "$TEST" == "sanity" ]]; then
echo "Robot Framework Cirros VNF Test"
@@ -81,10 +76,16 @@
ovf_converter $BASEDIR/images/cache/cirros-0.3.5-x86_64-disk.img -n cirros
python $TOPDIR/tools/vmware_ovf_upload.py $VCD_AUTH_URL $VCD_USERNAME $VCD_PASSWORD $VCD_ORGANIZATION $BASEDIR/images/cache/cirros.ovf
fi
- robot -d $BASEDIR/reports -i sanity $BASEDIR/testsuite/
+ robot --removekeywords tag:vim-setup --removekeywords WUKS -d $BASEDIR/reports -i sanity $BASEDIR/testsuite/
exit 0
elif [[ "$TEST" == "comprehensive" ]]; then
echo "Robot Framework Comprehensive Test"
+ echo "Installing chrome driver and chrome for UI testing"
+ # installing chrome driver and chrome for UI testing
+ curl -sS -o - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add -
+ echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list
+ apt-get update && apt-get -y install google-chrome-stable chromium-chromedriver
+ echo "Checking of image over VIMs"
mkdir -p $BASEDIR/images/cache
if [[ ! -z $OS_AUTH_URL ]]; then
(openstack image show ubuntu1604) || (wget -r -nc https://cloud-images.ubuntu.com/xenial/current/xenial-server-cloudimg-amd64-disk1.img -O $BASEDIR/images/cache/xenial-server-cloudimg-amd64-disk1.img && make $BASEDIR/images/cache/xenial-server-cloudimg-amd64-disk1.img && openstack image create --file $BASEDIR/images/cache/xenial-server-cloudimg-amd64-disk1.img ubuntu1604)
@@ -98,7 +99,7 @@
ovf_converter $BASEDIR/images/cache/xenial-server-cloudimg-amd64-disk1.img -n ubuntu1604
python $TOPDIR/tools/vmware_ovf_upload.py $VCD_AUTH_URL $VCD_USERNAME $VCD_PASSWORD $VCD_ORGANIZATION $BASEDIR/images/cache/ubuntu1604.ovf
fi
- robot -d $BASEDIR/reports -i comprehensive $BASEDIR/testsuite/
+ robot --removekeywords tag:vim-setup --removekeywords WUKS -d $BASEDIR/reports -i comprehensive $BASEDIR/testsuite/
exit 0
else
echo "wrong test provided"