aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristophe Lyon <christophe.lyon@linaro.org>2015-04-08 17:08:16 +0100
committerChristophe Lyon <christophe.lyon@linaro.org>2015-04-13 18:12:47 +0100
commit9f01221aeab83c59525d2914fb4adc609cb44222 (patch)
tree44aff62c14a79e905278ee1b98c85a78092a568b
parent0c5d8338da7472dc7919e2942ade0918bb8febf6 (diff)
Add support for ${reference_build}.jenkins-reference
This is a Jenkins field, where the user can provide a build number to use as a reference. If provided, jenkins.sh compares its results with the reference ones. Change-Id: I2ff746449d82dc8b47f29e40bc003d3c5faa8a83
-rwxr-xr-xjenkins.sh22
-rwxr-xr-xscripts/compare_tests3
2 files changed, 23 insertions, 2 deletions
diff --git a/jenkins.sh b/jenkins.sh
index 093b7ad8..f4ae9399 100755
--- a/jenkins.sh
+++ b/jenkins.sh
@@ -375,6 +375,25 @@ if test x"${sums}" != x -o x"${runtests}" != x"true"; then
xz ${logs_dir}/* || status=1
scp ${logs_dir}/* ${fileserver}:${basedir}/${dir}/ || status=1
rm -rf ${logs_dir} || status=1
+
+ # If the user supplied a reference build number, use it
+ if test x"${reference_build}" != x ; then
+ ref_dir="*/*/${arch}.${target}-${job}${reference_build}"
+ scp ${abe_dir}/scripts/compare_tests \
+ ${abe_dir}/scripts/compare_dg_tests.pl \
+ ${abe_dir}/scripts/unstable-tests.txt ${fileserver}:${basedir}/${dir}/ || status=1
+ ssh ${fileserver} bash ${basedir}/${dir}/compare_tests -target ${target} \
+ ${basedir}/${ref_dir} ${basedir}/${dir} || status=1
+ ssh ${fileserver} rm ${basedir}/${dir}/compare_tests \
+ ${basedir}/${dir}/compare_dg_tests.pl \
+ ${basedir}/${dir}/unstable-tests.txt
+
+ echo "### Compared REFERENCE:"
+ ssh ${fileserver} cat ${basedir}/${ref_dir}/manifest.txt
+ echo "### with THIS REVISION:"
+ ssh ${fileserver} cat ${basedir}/${dir}/manifest.txt
+ fi
+
# scp ${abe_dir}/tcwgweb.sh ${fileserver}:/tmp/tcwgweb$$.sh
# ssh ${fileserver} /tmp/tcwgweb$$.sh --email --base ${basedir}/${dir}
# ssh ${fileserver} rm -f /tmp/tcwgweb$$.sh
@@ -397,4 +416,7 @@ if test x"${sums}" != x -o x"${runtests}" != x"true"; then
fi
+wwwpath="`echo ${basedir}/${dir} | sed -e 's:/work::' -e 's:/space::'`"
+echo "Full build logs: http://abe.tcwglab.linaro.org${wwwpath}/"
+
exit $status
diff --git a/scripts/compare_tests b/scripts/compare_tests
index 12c67c3a..a216798d 100755
--- a/scripts/compare_tests
+++ b/scripts/compare_tests
@@ -38,8 +38,7 @@ EOUSAGE
export LC_ALL=C
-me="`which $0`"
-my_path="`dirname ${me}`"
+my_path="$(dirname $0)"
tool=gxx