X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=common%2Fscripts%2Fagl-extend-test.sh;fp=common%2Fscripts%2Fagl-extend-test.sh;h=fd3a4f837fa700811a83f097dc819e8cabb3e6bc;hb=2e5067e302bcfe08f970212f8d5c183561bf1f55;hp=0000000000000000000000000000000000000000;hpb=613e4a1ae1863799d388283f6de8e14a3aa4d584;p=src%2Fqa-testdefinitions.git diff --git a/common/scripts/agl-extend-test.sh b/common/scripts/agl-extend-test.sh new file mode 100755 index 0000000..fd3a4f8 --- /dev/null +++ b/common/scripts/agl-extend-test.sh @@ -0,0 +1,35 @@ +#!/bin/bash + +pre_check=`which agl-test` + +if [ -n "$pre_check" ] ; then + agl-test + echo "agl-extend-test is present" +else + echo "agl-test is not installed, abort this test" + exit 127 +fi + + +if [ -x ./artiproxy-upload.sh ] ; then + LOG_DIR=/var/run/agl-test/logs/log-to-report + ZIP_FILE=`ls ${LOG_DIR} | grep agl-test-log*` + + if [ -z $ZIP_FILE ] ; then + echo "Cannot find agl-extend-test log" + exit 1 + fi + + ./artiproxy-upload.sh $LOG_DIR $ZIP_FILE + if [ $? -eq 1 ] ; then + echo "Upload of ${ZIP_FILE} failed" + exit 1 + else + echo "Upload of test report successful" + exit 0 + fi + +else + echo "The file artiproxy-upload.sh does not exist" + exit 126 +fi