From b04be77d7424bd3f465fcee6562318d65492df73 Mon Sep 17 00:00:00 2001 From: Khouloud Touil Date: Wed, 13 Feb 2019 12:07:55 +0100 Subject: Enable the request of test report email Add new feature to the ci-managmenet that will request to send test report email to the specified email addresses in the automotive- testreports list after a certain delay (1 hour=3600 sec). This commit is accomplished based on the work of Corentin Labbe . Change-Id: I14350b13b5b6cf2550303999ced56055a392212b Signed-off-by: Khouloud Touil --- jjb/common/include-agl-lava-jobs-submit.sh | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/jjb/common/include-agl-lava-jobs-submit.sh b/jjb/common/include-agl-lava-jobs-submit.sh index 3ecb0d12..22dc0c3b 100644 --- a/jjb/common/include-agl-lava-jobs-submit.sh +++ b/jjb/common/include-agl-lava-jobs-submit.sh @@ -53,6 +53,23 @@ echo "####" echo "#### End: Output from LAVA job $job_id ####" echo "####" +# ask for email report + +if [ -z "$KCI_EMAIL_AUTH_TOKEN" ]; then + KCI_API='https://kernelci.dev.baylibre.com:8081' + TREE_NAME=$(grep kernel.tree: $JOB_FILE_NEW | sed 's,[[:space:]],,g' | cut -d: -f2) + BRANCH=$(grep git.branch: $JOB_FILE_NEW | sed 's,[[:space:]],,g' | cut -d: -f2) + GIT_DESCRIBE="$(grep kernel.version: $JOB_FILE_NEW | sed 's,[[:space:]],,g' | cut -d: -f2)" + lavacli --uri $LAVA_MASTER_URI results $job_id | grep '* [0-9]' |cut -d_ -f2- |cut -d. -f1 | sort | uniq > test_plans + if [ $? -eq 0 ] && [ -s test_plans ]; then + for plan in $(