[Functest] Fix the issue that no return_value exists 25/35625/2
authorhelenyao <yaohelan@huawei.com>
Thu, 1 Jun 2017 04:05:14 +0000 (12:05 +0800)
committerJose Lausuch <jose.lausuch@ericsson.com>
Thu, 1 Jun 2017 08:39:06 +0000 (08:39 +0000)
Save the execution return code to file before exiting

Change-Id: I73692754b4c4c4b584d5918db7ce446bad931920
Signed-off-by: helenyao <yaohelan@huawei.com>
jjb/functest/functest-suite.sh

index 228cc3d..5d1ed28 100755 (executable)
@@ -15,4 +15,7 @@ for test in ${tests[@]}; do
     let global_ret_val+=$?
 done
 
-exit $global_ret_val
+ret_val_file="${HOME}/opnfv/functest/results/${BRANCH##*/}/return_value"
+echo ${global_ret_val}>${ret_val_file}
+
+exit 0