From 44df87e7e653c41c2a820fdacb2f7ec0b66779c2 Mon Sep 17 00:00:00 2001 From: Bob Clary Date: Tue, 18 Aug 2009 00:30:00 -0700 Subject: [PATCH] bug 510901 - Sisyphus - support 1.9.3 branch. --- js/tests/bisect.sh | 551 +++++++++--------- js/tests/detect-universe.sh | 28 +- js/tests/known-failures.pl | 29 +- js/tests/process-logs.sh | 14 +- js/tests/runtests.sh | 45 +- js/tests/test.sh | 75 +-- testing/sisyphus/bin/build.sh | 12 +- testing/sisyphus/bin/builder.sh | 4 +- testing/sisyphus/bin/check-spider.sh | 21 +- testing/sisyphus/bin/checkout.sh | 98 +--- testing/sisyphus/bin/clean.sh | 4 +- testing/sisyphus/bin/clobber.sh | 8 +- testing/sisyphus/bin/create-profile.sh | 36 +- testing/sisyphus/bin/edit-talkback.sh | 22 +- testing/sisyphus/bin/install-build.sh | 73 ++- testing/sisyphus/bin/install-extensions.sh | 4 +- testing/sisyphus/bin/install-plugins.sh | 17 +- testing/sisyphus/bin/library.sh | 49 +- testing/sisyphus/bin/set-build-env.sh | 78 +-- testing/sisyphus/bin/smoke-build.sh | 96 --- testing/sisyphus/bin/spider.pl | 255 -------- testing/sisyphus/bin/test-setup.sh | 56 +- testing/sisyphus/bin/thunderbird.diff | 11 - testing/sisyphus/bin/uninstall-build.sh | 19 +- ...wnload-check,firefox-1.5.0-ftp,darwin.data | 11 - ...ownload-check,firefox-1.5.0-ftp,linux.data | 11 - .../download-check,firefox-1.5.0-ftp,nt.data | 11 - ...wnload-check,firefox-2.0.0-ftp,darwin.data | 11 - ...ownload-check,firefox-2.0.0-ftp,linux.data | 11 - .../download-check,firefox-2.0.0-ftp,nt.data | 11 - .../download-check,firefox-all,darwin.data | 11 - .../download-check,firefox-all,linux.data | 11 - .../data/download-check,firefox-all,nt.data | 11 - ...wnload-check,firefox-all-older,darwin.data | 11 - ...ownload-check,firefox-all-older,linux.data | 11 - .../download-check,firefox-all-older,nt.data | 11 - ...ad-check,thunderbird-1.5.0-ftp,darwin.data | 11 - ...oad-check,thunderbird-1.5.0-ftp,linux.data | 11 - ...wnload-check,thunderbird-1.5.0-ftp,nt.data | 11 - ...ad-check,thunderbird-2.0.0-ftp,darwin.data | 11 - ...oad-check,thunderbird-2.0.0-ftp,linux.data | 11 - ...wnload-check,thunderbird-2.0.0-ftp,nt.data | 11 - ...download-check,thunderbird-all,darwin.data | 11 - .../download-check,thunderbird-all,linux.data | 11 - .../download-check,thunderbird-all,nt.data | 11 - ...ad-check,thunderbird-all-older,darwin.data | 11 - ...oad-check,thunderbird-all-older,linux.data | 11 - ...wnload-check,thunderbird-all-older,nt.data | 11 - testing/sisyphus/data/fennec,1.9.1,debug.data | 10 - .../data/fennec,1.9.1,nightly-darwin.data | 10 - .../data/fennec,1.9.1,nightly-linux.data | 10 - .../data/fennec,1.9.1,nightly-nt.data | 10 - testing/sisyphus/data/fennec,1.9.1,opt.data | 10 - .../data/fennec,1.9.1-test,debug.data | 10 - .../sisyphus/data/fennec,1.9.1-test,opt.data | 10 - testing/sisyphus/data/fennec,1.9.2,debug.data | 10 - testing/sisyphus/data/fennec,1.9.2,opt.data | 10 - .../data/fennec,1.9.2-test,debug.data | 10 - .../sisyphus/data/fennec,1.9.2-test,opt.data | 10 - .../data/firefox,1.8.0,nightly-darwin.data | 9 - .../data/firefox,1.8.0,nightly-linux.data | 9 - .../data/firefox,1.8.0,nightly-nt.data | 9 - .../data/firefox,1.8.1,nightly-darwin.data | 9 - .../data/firefox,1.8.1,nightly-linux.data | 9 - .../data/firefox,1.8.1,nightly-nt.data | 9 - .../data/firefox,1.9.0,nightly-darwin.data | 2 +- .../data/firefox,1.9.0,nightly-linux.data | 2 +- .../data/firefox,1.9.0,nightly-nt.data | 2 +- .../data/firefox,1.9.0-jemalloc,debug.data | 8 - .../data/firefox,1.9.0-jemalloc,opt.data | 8 - .../firefox,1.9.0-jemalloc-test,debug.data | 8 - .../data/firefox,1.9.0-jemalloc-test,opt.data | 8 - .../data/firefox,1.9.1,nightly-darwin.data | 2 +- .../data/firefox,1.9.1,nightly-linux.data | 2 +- .../data/firefox,1.9.1,nightly-nt.data | 2 +- .../firefox,1.9.1-actionmonkey,debug.data | 10 - .../data/firefox,1.9.1-actionmonkey,opt.data | 10 - .../data/firefox,1.9.1-jemalloc,debug.data | 10 - .../data/firefox,1.9.1-jemalloc,opt.data | 10 - .../firefox,1.9.1-jemalloc-test,debug.data | 10 - .../data/firefox,1.9.1-jemalloc-test,opt.data | 10 - .../sisyphus/data/firefox,1.9.2,debug.data | 2 +- .../data/firefox,1.9.2,nightly-darwin.data | 10 + .../data/firefox,1.9.2,nightly-linux.data | 10 + .../data/firefox,1.9.2,nightly-nt.data | 10 + testing/sisyphus/data/firefox,1.9.2,opt.data | 2 +- .../data/firefox,1.9.2-test,debug.data | 2 +- .../sisyphus/data/firefox,1.9.2-test,opt.data | 2 +- .../data/firefox,1.9.3,nightly-darwin.data | 10 + .../data/firefox,1.9.3,nightly-linux.data | 10 + .../data/firefox,1.9.3,nightly-nt.data | 10 + ...a => firefox,1.9.3-tracemonkey,debug.data} | 8 +- ...ata => firefox,1.9.3-tracemonkey,opt.data} | 8 +- ...firefox,1.9.3-tracemonkey-test,debug.data} | 8 +- ...> firefox,1.9.3-tracemonkey-test,opt.data} | 8 +- testing/sisyphus/data/js,1.9.2,debug.data | 2 +- testing/sisyphus/data/js,1.9.2,opt.data | 2 +- .../data/js,1.9.2-narcissus,debug.data | 2 +- .../sisyphus/data/js,1.9.2-narcissus,opt.data | 2 +- .../sisyphus/data/js,1.9.2-test,debug.data | 6 + testing/sisyphus/data/js,1.9.2-test,opt.data | 6 + ...nmonkey,debug.data => js,1.9.3,debug.data} | 6 +- ...ctionmonkey,opt.data => js,1.9.3,opt.data} | 6 +- .../data/js,1.9.3-narcissus,debug.data | 7 + .../sisyphus/data/js,1.9.3-narcissus,opt.data | 7 + .../sisyphus/data/js,1.9.3-test,debug.data | 6 + testing/sisyphus/data/js,1.9.3-test,opt.data | 6 + ...g.data => js,1.9.3-tracemonkey,debug.data} | 4 +- ...opt.data => js,1.9.3-tracemonkey,opt.data} | 4 +- ...a => js,1.9.3-tracemonkey-test,debug.data} | 4 +- ...ata => js,1.9.3-tracemonkey-test,opt.data} | 4 +- .../data/thunderbird,1.8.0,debug.data | 8 - .../sisyphus/data/thunderbird,1.8.0,opt.data | 8 - .../data/thunderbird,1.8.0-test,debug.data | 8 - .../data/thunderbird,1.8.1,debug.data | 8 - .../sisyphus/data/thunderbird,1.8.1,opt.data | 8 - .../data/thunderbird,1.8.1-test,debug.data | 8 - .../data/thunderbird,1.9.0,debug.data | 8 - .../sisyphus/data/thunderbird,1.9.0,opt.data | 8 - .../data/thunderbird,1.9.0-test,debug.data | 8 - .../data/thunderbird,1.9.1,debug.data | 10 - .../sisyphus/data/thunderbird,1.9.1,opt.data | 10 - .../data/thunderbird,1.9.1-test,debug.data | 10 - 123 files changed, 665 insertions(+), 1748 deletions(-) delete mode 100755 testing/sisyphus/bin/smoke-build.sh delete mode 100755 testing/sisyphus/bin/spider.pl delete mode 100644 testing/sisyphus/bin/thunderbird.diff delete mode 100644 testing/sisyphus/data/download-check,firefox-1.5.0-ftp,darwin.data delete mode 100644 testing/sisyphus/data/download-check,firefox-1.5.0-ftp,linux.data delete mode 100644 testing/sisyphus/data/download-check,firefox-1.5.0-ftp,nt.data delete mode 100644 testing/sisyphus/data/download-check,firefox-2.0.0-ftp,darwin.data delete mode 100644 testing/sisyphus/data/download-check,firefox-2.0.0-ftp,linux.data delete mode 100644 testing/sisyphus/data/download-check,firefox-2.0.0-ftp,nt.data delete mode 100644 testing/sisyphus/data/download-check,firefox-all,darwin.data delete mode 100644 testing/sisyphus/data/download-check,firefox-all,linux.data delete mode 100644 testing/sisyphus/data/download-check,firefox-all,nt.data delete mode 100644 testing/sisyphus/data/download-check,firefox-all-older,darwin.data delete mode 100644 testing/sisyphus/data/download-check,firefox-all-older,linux.data delete mode 100644 testing/sisyphus/data/download-check,firefox-all-older,nt.data delete mode 100644 testing/sisyphus/data/download-check,thunderbird-1.5.0-ftp,darwin.data delete mode 100644 testing/sisyphus/data/download-check,thunderbird-1.5.0-ftp,linux.data delete mode 100644 testing/sisyphus/data/download-check,thunderbird-1.5.0-ftp,nt.data delete mode 100644 testing/sisyphus/data/download-check,thunderbird-2.0.0-ftp,darwin.data delete mode 100644 testing/sisyphus/data/download-check,thunderbird-2.0.0-ftp,linux.data delete mode 100644 testing/sisyphus/data/download-check,thunderbird-2.0.0-ftp,nt.data delete mode 100644 testing/sisyphus/data/download-check,thunderbird-all,darwin.data delete mode 100644 testing/sisyphus/data/download-check,thunderbird-all,linux.data delete mode 100644 testing/sisyphus/data/download-check,thunderbird-all,nt.data delete mode 100644 testing/sisyphus/data/download-check,thunderbird-all-older,darwin.data delete mode 100644 testing/sisyphus/data/download-check,thunderbird-all-older,linux.data delete mode 100644 testing/sisyphus/data/download-check,thunderbird-all-older,nt.data delete mode 100644 testing/sisyphus/data/fennec,1.9.1,debug.data delete mode 100644 testing/sisyphus/data/fennec,1.9.1,nightly-darwin.data delete mode 100644 testing/sisyphus/data/fennec,1.9.1,nightly-linux.data delete mode 100644 testing/sisyphus/data/fennec,1.9.1,nightly-nt.data delete mode 100644 testing/sisyphus/data/fennec,1.9.1,opt.data delete mode 100644 testing/sisyphus/data/fennec,1.9.1-test,debug.data delete mode 100644 testing/sisyphus/data/fennec,1.9.1-test,opt.data delete mode 100644 testing/sisyphus/data/fennec,1.9.2,debug.data delete mode 100644 testing/sisyphus/data/fennec,1.9.2,opt.data delete mode 100644 testing/sisyphus/data/fennec,1.9.2-test,debug.data delete mode 100644 testing/sisyphus/data/fennec,1.9.2-test,opt.data delete mode 100644 testing/sisyphus/data/firefox,1.8.0,nightly-darwin.data delete mode 100644 testing/sisyphus/data/firefox,1.8.0,nightly-linux.data delete mode 100644 testing/sisyphus/data/firefox,1.8.0,nightly-nt.data delete mode 100644 testing/sisyphus/data/firefox,1.8.1,nightly-darwin.data delete mode 100644 testing/sisyphus/data/firefox,1.8.1,nightly-linux.data delete mode 100644 testing/sisyphus/data/firefox,1.8.1,nightly-nt.data delete mode 100644 testing/sisyphus/data/firefox,1.9.0-jemalloc,debug.data delete mode 100644 testing/sisyphus/data/firefox,1.9.0-jemalloc,opt.data delete mode 100644 testing/sisyphus/data/firefox,1.9.0-jemalloc-test,debug.data delete mode 100644 testing/sisyphus/data/firefox,1.9.0-jemalloc-test,opt.data delete mode 100644 testing/sisyphus/data/firefox,1.9.1-actionmonkey,debug.data delete mode 100644 testing/sisyphus/data/firefox,1.9.1-actionmonkey,opt.data delete mode 100644 testing/sisyphus/data/firefox,1.9.1-jemalloc,debug.data delete mode 100644 testing/sisyphus/data/firefox,1.9.1-jemalloc,opt.data delete mode 100644 testing/sisyphus/data/firefox,1.9.1-jemalloc-test,debug.data delete mode 100644 testing/sisyphus/data/firefox,1.9.1-jemalloc-test,opt.data create mode 100644 testing/sisyphus/data/firefox,1.9.2,nightly-darwin.data create mode 100644 testing/sisyphus/data/firefox,1.9.2,nightly-linux.data create mode 100644 testing/sisyphus/data/firefox,1.9.2,nightly-nt.data create mode 100644 testing/sisyphus/data/firefox,1.9.3,nightly-darwin.data create mode 100644 testing/sisyphus/data/firefox,1.9.3,nightly-linux.data create mode 100644 testing/sisyphus/data/firefox,1.9.3,nightly-nt.data rename testing/sisyphus/data/{firefox,1.9.1-tracemonkey,debug.data => firefox,1.9.3-tracemonkey,debug.data} (65%) rename testing/sisyphus/data/{firefox,1.9.1-tracemonkey,opt.data => firefox,1.9.3-tracemonkey,opt.data} (65%) rename testing/sisyphus/data/{firefox,1.9.1-tracemonkey-test,debug.data => firefox,1.9.3-tracemonkey-test,debug.data} (66%) rename testing/sisyphus/data/{firefox,1.9.1-tracemonkey-test,opt.data => firefox,1.9.3-tracemonkey-test,opt.data} (65%) create mode 100644 testing/sisyphus/data/js,1.9.2-test,debug.data create mode 100644 testing/sisyphus/data/js,1.9.2-test,opt.data rename testing/sisyphus/data/{js,1.9.1-actionmonkey,debug.data => js,1.9.3,debug.data} (56%) rename testing/sisyphus/data/{js,1.9.1-actionmonkey,opt.data => js,1.9.3,opt.data} (56%) create mode 100644 testing/sisyphus/data/js,1.9.3-narcissus,debug.data create mode 100644 testing/sisyphus/data/js,1.9.3-narcissus,opt.data create mode 100644 testing/sisyphus/data/js,1.9.3-test,debug.data create mode 100644 testing/sisyphus/data/js,1.9.3-test,opt.data rename testing/sisyphus/data/{js,1.9.1-tracemonkey,debug.data => js,1.9.3-tracemonkey,debug.data} (81%) rename testing/sisyphus/data/{js,1.9.1-tracemonkey,opt.data => js,1.9.3-tracemonkey,opt.data} (81%) rename testing/sisyphus/data/{js,1.9.1-tracemonkey-test,debug.data => js,1.9.3-tracemonkey-test,debug.data} (79%) rename testing/sisyphus/data/{js,1.9.1-tracemonkey-test,opt.data => js,1.9.3-tracemonkey-test,opt.data} (79%) delete mode 100644 testing/sisyphus/data/thunderbird,1.8.0,debug.data delete mode 100644 testing/sisyphus/data/thunderbird,1.8.0,opt.data delete mode 100644 testing/sisyphus/data/thunderbird,1.8.0-test,debug.data delete mode 100644 testing/sisyphus/data/thunderbird,1.8.1,debug.data delete mode 100644 testing/sisyphus/data/thunderbird,1.8.1,opt.data delete mode 100644 testing/sisyphus/data/thunderbird,1.8.1-test,debug.data delete mode 100644 testing/sisyphus/data/thunderbird,1.9.0,debug.data delete mode 100644 testing/sisyphus/data/thunderbird,1.9.0,opt.data delete mode 100644 testing/sisyphus/data/thunderbird,1.9.0-test,debug.data delete mode 100644 testing/sisyphus/data/thunderbird,1.9.1,debug.data delete mode 100644 testing/sisyphus/data/thunderbird,1.9.1,opt.data delete mode 100644 testing/sisyphus/data/thunderbird,1.9.1-test,debug.data diff --git a/js/tests/bisect.sh b/js/tests/bisect.sh index 183d8370c20f..d923f1f7ea42 100755 --- a/js/tests/bisect.sh +++ b/js/tests/bisect.sh @@ -41,7 +41,7 @@ if [[ -z "$TEST_DIR" ]]; then cat < /dev/null - export MOZ_CO_DATE="$bisect_bad" - eval $TEST_DIR/bin/builder.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -B "checkout" > /dev/null - bisect_log=`eval $TEST_JSDIR/runtests.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -I $bisect_test -B "build" -c -t -X /dev/null 2>&1 | grep '_js.log $' | sed 's|log: \([^ ]*\) |\1|'` - if [[ -z "$bisect_log" ]]; then - echo "test $bisect_test not run." + echo "checking that the test fails in the bad revision $bisect_bad" + eval $TEST_DIR/bin/builder.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -B "clobber" > /dev/null + export MOZ_CO_DATE="$bisect_bad" + eval $TEST_DIR/bin/builder.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -B "checkout" > /dev/null + bisect_log=`eval $TEST_JSDIR/runtests.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -I $bisect_test -B "build" -c -t -X /dev/null 2>&1 | grep '_js.log $' | sed 's|log: \([^ ]*\) |\1|'` + if [[ -z "$bisect_log" ]]; then + echo "test $bisect_test not run." + else + if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then + echo "test failure $bisect_test.*$bisect_string found, bad revision $bisect_bad confirmed" + bad_confirmed=1 else - if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then - echo "test failure $bisect_test.*$bisect_string found, bad revision $bisect_bad confirmed" - bad_confirmed=1 - else - echo "test failure $bisect_test.*$bisect_string not found, bad revision $bisect_bad *not* confirmed" - fi + echo "test failure $bisect_test.*$bisect_string not found, bad revision $bisect_bad *not* confirmed" + fi + fi + + if [[ "$bad_confirmed" != "1" ]]; then + error "bad revision not confirmed"; + fi + + echo "checking that the test passes in the good revision $bisect_good" + eval $TEST_DIR/bin/builder.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -B "clobber" > /dev/null + export MOZ_CO_DATE="$bisect_good" + eval $TEST_DIR/bin/builder.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -B "checkout" > /dev/null + + bisect_log=`eval $TEST_JSDIR/runtests.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -I $bisect_test -B "build" -c -t -X /dev/null 2>&1 | grep '_js.log $' | sed 's|log: \([^ ]*\) |\1|'` + if [[ -z "$bisect_log" ]]; then + echo "test $bisect_test not run." + else + if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then + echo "test failure $bisect_test.*$bisect_string found, good revision $bisect_good *not* confirmed" + else + echo "test failure $bisect_test.*$bisect_string not found, good revision $bisect_good confirmed" + good_confirmed=1 + fi + fi + + if [[ "$good_confirmed" != "1" ]]; then + error "good revision not confirmed"; + fi + + echo "bisecting $bisect_start to $bisect_stop" + + # + # place an array of dates of checkins into an array and + # perform a binary search on those dates. + # + declare -a seconds_array date_array + + # load the cvs checkin dates into an array. the array will look like + # date_array[i] date value + # date_array[i+1] time value + + pushd $BUILDTREE/mozilla + date_array=(`cvs -q -z3 log -N -d "$bisect_start<$bisect_stop" | grep "^date: " | sed 's|^date: \([^;]*\).*|\1|' | sort -u`) + popd + + let seconds_index=0 1 + let date_index=0 1 + + while (( $date_index < ${#date_array[@]} )); do + seconds_array[$seconds_index]=`dateparse.pl "${date_array[$date_index]} ${date_array[$date_index+1]} UTC"` + let seconds_index=$seconds_index+1 + let date_index=$date_index+2 + done + + let seconds_index_start=0 1 + let seconds_index_stop=${#seconds_array[@]} + + while true; do + + if (( $seconds_index_start+1 >= $seconds_index_stop )); then + echo "*** date `perl -e 'print scalar localtime $ARGV[0];' ${seconds_array[$seconds_index_stop]}` found ***" + break; fi - if [[ "$bad_confirmed" != "1" ]]; then - error "bad revision not confirmed"; - fi - - echo "checking that the test passes in the good revision $bisect_good" + unset result + + # clobber before setting new changeset. eval $TEST_DIR/bin/builder.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -B "clobber" > /dev/null - export MOZ_CO_DATE="$bisect_good" + + let seconds_index_middle="($seconds_index_start + $seconds_index_stop)/2" + let seconds_middle="${seconds_array[$seconds_index_middle]}" + + bisect_middle="`perl -e 'print scalar localtime $ARGV[0];' $seconds_middle`" + export MOZ_CO_DATE="$bisect_middle" + echo "testing $MOZ_CO_DATE" + eval $TEST_DIR/bin/builder.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -B "checkout" > /dev/null bisect_log=`eval $TEST_JSDIR/runtests.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -I $bisect_test -B "build" -c -t -X /dev/null 2>&1 | grep '_js.log $' | sed 's|log: \([^ ]*\) |\1|'` if [[ -z "$bisect_log" ]]; then - echo "test $bisect_test not run." + echo "test $bisect_test not run. Skipping changeset" + let seconds_index_start=$seconds_index_start+1 else - if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then - echo "test failure $bisect_test.*$bisect_string found, good revision $bisect_good *not* confirmed" - else - echo "test failure $bisect_test.*$bisect_string not found, good revision $bisect_good confirmed" - good_confirmed=1 - fi - fi - - if [[ "$good_confirmed" != "1" ]]; then - error "good revision not confirmed"; - fi - - echo "bisecting $bisect_start to $bisect_stop" - - # - # place an array of dates of checkins into an array and - # perform a binary search on those dates. - # - declare -a seconds_array date_array - - # load the cvs checkin dates into an array. the array will look like - # date_array[i] date value - # date_array[i+1] time value - - pushd $BUILDTREE/mozilla - date_array=(`cvs -q -z3 log -N -d "$bisect_start<$bisect_stop" | grep "^date: " | sed 's|^date: \([^;]*\).*|\1|' | sort -u`) - popd - - let seconds_index=0 1 - let date_index=0 1 - - while (( $date_index < ${#date_array[@]} )); do - seconds_array[$seconds_index]=`dateparse.pl "${date_array[$date_index]} ${date_array[$date_index+1]} UTC"` - let seconds_index=$seconds_index+1 - let date_index=$date_index+2 - done - - let seconds_index_start=0 1 - let seconds_index_stop=${#seconds_array[@]} - - while true; do - - if (( $seconds_index_start+1 >= $seconds_index_stop )); then - echo "*** date `perl -e 'print scalar localtime $ARGV[0];' ${seconds_array[$seconds_index_stop]}` found ***" - break; - fi - - unset result - - # clobber before setting new changeset. - eval $TEST_DIR/bin/builder.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -B "clobber" > /dev/null - - let seconds_index_middle="($seconds_index_start + $seconds_index_stop)/2" - let seconds_middle="${seconds_array[$seconds_index_middle]}" - - bisect_middle="`perl -e 'print scalar localtime $ARGV[0];' $seconds_middle`" - export MOZ_CO_DATE="$bisect_middle" - echo "testing $MOZ_CO_DATE" - - eval $TEST_DIR/bin/builder.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -B "checkout" > /dev/null - - bisect_log=`eval $TEST_JSDIR/runtests.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -I $bisect_test -B "build" -c -t -X /dev/null 2>&1 | grep '_js.log $' | sed 's|log: \([^ ]*\) |\1|'` - if [[ -z "$bisect_log" ]]; then - echo "test $bisect_test not run. Skipping changeset" - let seconds_index_start=$seconds_index_start+1 - else - if [[ "$searchtype" == "regression" ]]; then - # searching for a regression, pass -> fail - if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then - echo "test failure $bisect_test.*$bisect_string found" - let seconds_index_stop=$seconds_index_middle; - else - echo "test failure $bisect_test.*$bisect_string not found" - let seconds_index_start=$seconds_index_middle - fi + if [[ "$searchtype" == "regression" ]]; then + # searching for a regression, pass -> fail + if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then + echo "test failure $bisect_test.*$bisect_string found" + let seconds_index_stop=$seconds_index_middle; else - # searching for a fix, fail -> pass - if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then - echo "test failure $bisect_test.*$bisect_string found" - let seconds_index_start=$seconds_index_middle - else - echo "test failure $bisect_test.*$bisect_string not found" - let seconds_index_stop=$seconds_index_middle - fi + echo "test failure $bisect_test.*$bisect_string not found" + let seconds_index_start=$seconds_index_middle + fi + else + # searching for a fix, fail -> pass + if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then + echo "test failure $bisect_test.*$bisect_string found" + let seconds_index_start=$seconds_index_middle + else + echo "test failure $bisect_test.*$bisect_string not found" + let seconds_index_stop=$seconds_index_middle fi fi + fi - done - ;; + done +else + # + # binary search using mercurial + # - 1.9.1|1.9.2) - # - # binary search using mercurial - # + TEST_MOZILLA_HG_LOCAL=${TEST_MOZILLA_HG_LOCAL:-$BUILDDIR/hg.mozilla.org/`basename $TEST_MOZILLA_HG`} + hg -R $TEST_MOZILLA_HG_LOCAL pull -r tip - TEST_MOZILLA_HG_LOCAL=${TEST_MOZILLA_HG_LOCAL:-$BUILDDIR/hg.mozilla.org/`basename $TEST_MOZILLA_HG`} - hg -R $TEST_MOZILLA_HG_LOCAL pull -r tip + REPO=$BUILDTREE/mozilla + hg -R $REPO pull -r tip - REPO=$BUILDTREE/mozilla - hg -R $REPO pull -r tip + # convert revision numbers to local revision numbers for ordering + localgood=`hg -R $REPO id -n -r $bisect_good` + localbad=`hg -R $REPO id -n -r $bisect_bad` - # convert revision numbers to local revision numbers for ordering - localgood=`hg -R $REPO id -n -r $bisect_good` - localbad=`hg -R $REPO id -n -r $bisect_bad` + # if good < bad, then we are searching for a regression, + # i.e. the first bad changeset + # if bad < good, then we are searching for a fix. + # i.e. the first good changeset. so we reverse the nature + # of good and bad. - # if good < bad, then we are searching for a regression, - # i.e. the first bad changeset - # if bad < good, then we are searching for a fix. - # i.e. the first good changeset. so we reverse the nature - # of good and bad. - - if (( $localgood < $localbad )); then - cat < /dev/null + fi + hg -R $REPO update -C -r $bisect_bad + bisect_log=`eval $TEST_JSDIR/runtests.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -I $bisect_test -B "build" -c -t -X /dev/null 2>&1 | grep '_js.log $' | sed 's|log: \([^ ]*\) |\1|'` + if [[ -z "$bisect_log" ]]; then + echo "test $bisect_test not run." + else + if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then + echo "test failure $bisect_test.*$bisect_string found, bad revision $localbad:$bisect_bad confirmed" + bad_confirmed=1 + else + echo "test failure $bisect_test.*$bisect_string not found, bad revision $localbad:$bisect_bad *not* confirmed" + fi + fi + + if [[ "$bad_confirmed" != "1" ]]; then + error "bad revision not confirmed"; + fi + + echo "checking that the test passes in the good revision $localgood:$bisect_good" + if [[ -z "$bisect_depends" ]]; then + eval $TEST_DIR/bin/builder.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -B "clobber" > /dev/null + fi + hg -R $REPO update -C -r $bisect_good + bisect_log=`eval $TEST_JSDIR/runtests.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -I $bisect_test -B "build" -c -t -X /dev/null 2>&1 | grep '_js.log $' | sed 's|log: \([^ ]*\) |\1|'` + if [[ -z "$bisect_log" ]]; then + echo "test $bisect_test not run." + else + if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then + echo "test failure $bisect_test.*$bisect_string found, good revision $localgood:$bisect_good *not* confirmed" + else + echo "test failure $bisect_test.*$bisect_string not found, good revision $localgood:$bisect_good confirmed" + good_confirmed=1 + fi + fi + + if [[ "$good_confirmed" != "1" ]]; then + error "good revision not confirmed"; + fi + + echo "bisecting $REPO $bisect_start to $bisect_stop" + hg -q -R $REPO bisect --reset + hg -q -R $REPO bisect --good $bisect_start + hg -q -R $REPO bisect --bad $bisect_stop + + while true; do + unset result + + # clobber before setting new changeset. if [[ -z "$bisect_depends" ]]; then eval $TEST_DIR/bin/builder.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -B "clobber" > /dev/null fi - hg -R $REPO update -C -r $bisect_bad + + # remove extraneous in-tree changes + # See https://bugzilla.mozilla.org/show_bug.cgi?id=480680 for details + # of why this is necessary. + hg -R $REPO update -C + + hg -R $REPO bisect + # save the revision id so we can update to it discarding local + # changes in the working directory. + rev=`hg -R $REPO id -i` + bisect_log=`eval $TEST_JSDIR/runtests.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -I $bisect_test -B "build" -c -t -X /dev/null 2>&1 | grep '_js.log $' | sed 's|log: \([^ ]*\) |\1|'` + # remove extraneous in-tree changes + # See https://bugzilla.mozilla.org/show_bug.cgi?id=480680 for details + # of why this is necessary. + hg -R $REPO update -C -r $rev + if [[ -z "$bisect_log" ]]; then - echo "test $bisect_test not run." + echo "test $bisect_test not run. Skipping changeset" + hg -R $REPO bisect --skip else - if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then - echo "test failure $bisect_test.*$bisect_string found, bad revision $localbad:$bisect_bad confirmed" - bad_confirmed=1 - else - echo "test failure $bisect_test.*$bisect_string not found, bad revision $localbad:$bisect_bad *not* confirmed" - fi - fi - - if [[ "$bad_confirmed" != "1" ]]; then - error "bad revision not confirmed"; - fi - - echo "checking that the test passes in the good revision $localgood:$bisect_good" - if [[ -z "$bisect_depends" ]]; then - eval $TEST_DIR/bin/builder.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -B "clobber" > /dev/null - fi - hg -R $REPO update -C -r $bisect_good - bisect_log=`eval $TEST_JSDIR/runtests.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -I $bisect_test -B "build" -c -t -X /dev/null 2>&1 | grep '_js.log $' | sed 's|log: \([^ ]*\) |\1|'` - if [[ -z "$bisect_log" ]]; then - echo "test $bisect_test not run." - else - if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then - echo "test failure $bisect_test.*$bisect_string found, good revision $localgood:$bisect_good *not* confirmed" - else - echo "test failure $bisect_test.*$bisect_string not found, good revision $localgood:$bisect_good confirmed" - good_confirmed=1 - fi - fi - - if [[ "$good_confirmed" != "1" ]]; then - error "good revision not confirmed"; - fi - - echo "bisecting $REPO $bisect_start to $bisect_stop" - hg -q -R $REPO bisect --reset - hg -q -R $REPO bisect --good $bisect_start - hg -q -R $REPO bisect --bad $bisect_stop - - while true; do - unset result - - # clobber before setting new changeset. - if [[ -z "$bisect_depends" ]]; then - eval $TEST_DIR/bin/builder.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -B "clobber" > /dev/null - fi - - # remove extraneous in-tree changes - # See https://bugzilla.mozilla.org/show_bug.cgi?id=480680 for details - # of why this is necessary. - hg -R $REPO update -C - - hg -R $REPO bisect - # save the revision id so we can update to it discarding local - # changes in the working directory. - rev=`hg -R $REPO id -i` - - bisect_log=`eval $TEST_JSDIR/runtests.sh -p $bisect_product -b $bisect_branch $bisect_extraflag -T $bisect_buildtype -I $bisect_test -B "build" -c -t -X /dev/null 2>&1 | grep '_js.log $' | sed 's|log: \([^ ]*\) |\1|'` - # remove extraneous in-tree changes - # See https://bugzilla.mozilla.org/show_bug.cgi?id=480680 for details - # of why this is necessary. - hg -R $REPO update -C -r $rev - - if [[ -z "$bisect_log" ]]; then - echo "test $bisect_test not run. Skipping changeset" - hg -R $REPO bisect --skip - else - if [[ "$searchtype" == "regression" ]]; then - # searching for a regression - # the result is considered good when the test does not appear in the failure log - if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then - echo "test failure $bisect_test.*$bisect_string found, marking revision bad" - if ! result=`hg -R $REPO bisect --bad 2>&1`; then - echo "bisect bad failed" - error "$result" - fi - else - echo "test failure $bisect_test.*$bisect_string not found, marking revision good" - if ! result=`hg -R $REPO bisect --good 2>&1`; then - echo "bisect good failed" - error "$result" - fi + if [[ "$searchtype" == "regression" ]]; then + # searching for a regression + # the result is considered good when the test does not appear in the failure log + if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then + echo "test failure $bisect_test.*$bisect_string found, marking revision bad" + if ! result=`hg -R $REPO bisect --bad 2>&1`; then + echo "bisect bad failed" + error "$result" fi else - # searching for a fix - # the result is considered good when the test does appear in the failure log - if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then - echo "test failure $bisect_test.*$bisect_string found, marking revision good" - if ! result=`hg -R $REPO bisect --good 2>&1`; then - echo "bisect good failed" - error "$result" - fi - else - echo "test failure $bisect_test.*$bisect_string not found, marking revision bad" - if ! result=`hg -R $REPO bisect --bad 2>&1`; then - echo "bisect bad failed" - error "$result" - fi + echo "test failure $bisect_test.*$bisect_string not found, marking revision good" + if ! result=`hg -R $REPO bisect --good 2>&1`; then + echo "bisect good failed" + error "$result" + fi + fi + else + # searching for a fix + # the result is considered good when the test does appear in the failure log + if egrep -q "$bisect_test.*$bisect_string" ${bisect_log}-results-failures.log; then + echo "test failure $bisect_test.*$bisect_string found, marking revision good" + if ! result=`hg -R $REPO bisect --good 2>&1`; then + echo "bisect good failed" + error "$result" + fi + else + echo "test failure $bisect_test.*$bisect_string not found, marking revision bad" + if ! result=`hg -R $REPO bisect --bad 2>&1`; then + echo "bisect bad failed" + error "$result" fi fi fi + fi - if echo $result | egrep -q "The first (good|bad) revision is:"; then - result_revision=`echo $result | sed "s|The first .* revision is:.*changeset: [0-9]*:\([^ ]*\).*|\1|"` - echo $result | sed "s|The first .* revision is:|$searchtype|" - echo "*** revision $result_revision found ***" - break - fi + if echo $result | egrep -q "The first (good|bad) revision is:"; then + result_revision=`echo $result | sed "s|The first .* revision is:.*changeset: [0-9]*:\([^ ]*\).*|\1|"` + echo $result | sed "s|The first .* revision is:|$searchtype|" + echo "*** revision $result_revision found ***" + break + fi - done - ;; -esac + done +fi diff --git a/js/tests/detect-universe.sh b/js/tests/detect-universe.sh index b750a304182c..878b8c47815e 100755 --- a/js/tests/detect-universe.sh +++ b/js/tests/detect-universe.sh @@ -41,7 +41,7 @@ if [[ -z "$TEST_DIR" ]]; then cat <> $urllist echo "
  • $jsfile
  • " >> $urlhtml fi @@ -497,8 +500,8 @@ EOF if [[ -z "$filesonly" ]]; then echo "JavaScriptTest: Begin Run" - cat "$urllist" | while read url; - do + cat "$urllist" | while read url; + do edit-talkback.sh -p "$product" -b "$branch" -x "$executablepath" -i "$url" jsfile=`echo $url | sed "s|http://$TEST_HTTP/$TEST_WWW_JS/js-test-driver-standards.html?test=\([^;]*\);.*|\1|"` echo "JavaScriptTest: Begin Test $jsfile" diff --git a/testing/sisyphus/bin/build.sh b/testing/sisyphus/bin/build.sh index 53f6453623a4..b7cef8481aac 100755 --- a/testing/sisyphus/bin/build.sh +++ b/testing/sisyphus/bin/build.sh @@ -41,7 +41,7 @@ source $TEST_DIR/bin/library.sh source $TEST_DIR/bin/set-build-env.sh $@ case $product in - firefox|thunderbird|fennec) + firefox) cd $BUILDTREE/mozilla if ! $buildbash $bashlogin -c "export PATH=\"$BUILDPATH\"; cd $BUILDTREE/mozilla; make -f client.mk build" 2>&1; then @@ -64,18 +64,10 @@ case $product in if [[ "$buildtype" == "debug" ]]; then if [[ "$product" == "firefox" ]]; then executablepath=$product-$buildtype/dist/FirefoxDebug.app/Contents/MacOS - elif [[ "$product" == "thunderbird" ]]; then - executablepath=$product-$buildtype/dist/ThunderbirdDebug.app/Contents/MacOS - elif [[ "$product" == "fennec" ]]; then - executablepath=$product-$buildtype/dist/FennecDebug.app/Contents/MacOS fi else if [[ "$product" == "firefox" ]]; then executablepath=$product-$buildtype/dist/Firefox.app/Contents/MacOS - elif [[ "$product" == "thunderbird" ]]; then - executablepath=$product-$buildtype/dist/Thunderbird.app/Contents/MacOS - elif [[ "$product" == "fennec" ]]; then - executablepath=$product-$buildtype/dist/Fennec.app/Contents/MacOS fi fi ;; @@ -84,7 +76,7 @@ case $product in ;; esac - if [[ "$OSID" != "nt" && "$product" != "fennec" ]]; then + if [[ "$OSID" != "nt" ]]; then # # patch unix-like startup scripts to exec instead of # forking new processes diff --git a/testing/sisyphus/bin/builder.sh b/testing/sisyphus/bin/builder.sh index 6a6aa8c4e700..a8f12ecbb377 100755 --- a/testing/sisyphus/bin/builder.sh +++ b/testing/sisyphus/bin/builder.sh @@ -53,8 +53,8 @@ $SCRIPT -p products -b branches -B buildcommands -T buildtypes [-e extra] [-d da variable description =============== =========================================================== --p products required. one or more of js firefox thunderbird fennec --b branches required. one or more of 1.8.0 1.8.1 1.9.0 1.9.1 1.9.2 +-p products required. one or more of js firefox +-b branches required. one or more of supported branches. see library.sh. -B buildcommands required. one or more of clean clobber checkout build -T buildtypes required. one or more of opt debug -e extra optional. extra qualifier to pick build tree and mozconfig. diff --git a/testing/sisyphus/bin/check-spider.sh b/testing/sisyphus/bin/check-spider.sh index b910debb6b76..c288526faee9 100755 --- a/testing/sisyphus/bin/check-spider.sh +++ b/testing/sisyphus/bin/check-spider.sh @@ -48,21 +48,21 @@ options="p:b:x:N:d:" function usage() { cat <&1; then - error "during checkout of $project tree" $LINENO - fi - ;; - - 1.9.1|1.9.2) - - # do not use mozilla-build on windows systems as we - # must use the cygwin python with the cygwin mercurial. - - if ! python client.py checkout; then - error "during checkout of $project tree" $LINENO - fi - ;; - - *) - error "branch $branch not yet supported" - ;; - esac - ;; - - fennec) - - case $branch in - 1.9.1|1.9.2) - - # XXX need to generalize the mobile-browser repository - if [[ ! -d mobile/.hg ]]; then - if ! hg clone http://hg.mozilla.org/mobile-browser $BUILDTREE/mozilla/mobile; then - error "during hg clone of http://hg.mozilla.org/mobile-browser" $LINENO - fi - fi - - cd mobile - hg pull - if [[ "$OSID" == "nt" ]]; then - # remove spurious lock file - rm -f .hg/wlock.lnk - fi - hg update -C - - # XXX need to deal with mobile revisions from different repositories - - cd ../ - # do not use mozilla-build on windows systems as we # must use the cygwin python with the cygwin mercurial. @@ -217,14 +135,10 @@ case $product in error "during checkout of $project tree" $LINENO fi ;; - - *) - error "branch $branch not yet supported" - ;; esac ;; - js) + js) case $branch in 1.8.*|1.9.0) @@ -247,9 +161,9 @@ case $product in fi ;; - 1.9.1|1.9.2) + *) - # do not use mozilla-build on windows systems as we + # do not use mozilla-build on windows systems as we # must use the cygwin python with the cygwin mercurial. if ! python client.py checkout; then @@ -258,10 +172,6 @@ case $product in cd js/src ;; - - *) - error "branch $branch not yet supported" - ;; esac # end for js shell ;; diff --git a/testing/sisyphus/bin/clean.sh b/testing/sisyphus/bin/clean.sh index e18d8d7023fc..b52095e420f3 100755 --- a/testing/sisyphus/bin/clean.sh +++ b/testing/sisyphus/bin/clean.sh @@ -41,7 +41,7 @@ source $TEST_DIR/bin/library.sh source $TEST_DIR/bin/set-build-env.sh $@ case $product in - firefox|thunderbird|fennec) + firefox) if ! $buildbash $bashlogin -c "cd $BUILDTREE/mozilla; make -f client.mk clean" 2>&1; then error "during client.mk clean" $LINENO @@ -69,7 +69,7 @@ case $product in fi cd "$BUILDTREE/mozilla/js/src" - eval "$AUTOCONF" + eval "$AUTOCONF" fi diff --git a/testing/sisyphus/bin/clobber.sh b/testing/sisyphus/bin/clobber.sh index caf37da50202..c50e29e55659 100755 --- a/testing/sisyphus/bin/clobber.sh +++ b/testing/sisyphus/bin/clobber.sh @@ -43,15 +43,15 @@ source $TEST_DIR/bin/set-build-env.sh $@ if [[ ! -e "$BUILDDIR" ]]; then echo "build directory \"$BUILDDIR\" doesn't exist, ignoring clobber" exit -fi +fi case $product in - firefox|thunderbird|fennec) + firefox) if [[ ! -e "$executablepath" ]]; then echo "executable path $executablepath doesn't exist, ignoring clobber" exit - fi + fi if ! $buildbash $bashlogin -c "export PATH=\"$BUILDPATH\"; cd $BUILDTREE/mozilla; make -f client.mk clobber" 2>&1; then echo "error during client.mk clobber" $LINENO @@ -65,7 +65,7 @@ case $product in if [[ ! -e "$jsshellsourcepath" ]]; then echo "javascript shell source path $jsshellsourcepath doesn't exist, ignoring clobber" exit - fi + fi if [[ -e "$BUILDTREE/mozilla/js/src/configure.in" ]]; then rm -f $BUILDTREE/mozilla/js/src/configure fi diff --git a/testing/sisyphus/bin/create-profile.sh b/testing/sisyphus/bin/create-profile.sh index fa1fe8af9036..d66e22f33f6b 100755 --- a/testing/sisyphus/bin/create-profile.sh +++ b/testing/sisyphus/bin/create-profile.sh @@ -46,23 +46,23 @@ options="p:b:x:D:N:L:U:d:" function usage() { cat <&2 if [[ "$0" == "-bash" || "$0" == "bash" ]]; then return 0 fi exit 2 -} +} if [[ -z "$LIBRARYSH" ]]; then @@ -112,36 +112,22 @@ if [[ -z "$LIBRARYSH" ]]; then local branch=$2 case $product in - js|firefox|thunderbird|fennec) + js|firefox) ;; *) - error "product \"$product\" must be one of firefox, thunderbird, or fennec" $LINENO + error "product \"$product\" must be one of js or firefox" $LINENO esac case $branch in - 1.8.0|1.8.1|1.9.0|1.9.1|1.9.2) + 1.8.0|1.8.1|1.9.0|1.9.1|1.9.2|1.9.3) ;; *) - error "branch \"$branch\" must be one of 1.8.0, 1.8.1, 1.9.0 1.9.1 1.9.2" $LINENO + error "branch \"$branch\" must be one of 1.8.0 1.8.1 1.9.0 1.9.1 1.9.2 1.9.3" $LINENO esac - # special case thunderbird and fennec due to their different - # repository and build tree structures. - case "$product" in - "thunderbird") - if [[ $branch == "1.9.2" ]]; then - error "thunderbird on branch 1.9.2 is not supported" - fi - ;; - "fennec") - if [[ $branch != "1.9.1" && "$branch" != "1.9.2" ]]; then - error "fennec on branch $branch is not supported" - fi - ;; - esac - } + } - # Darwin 8.11.1's |which| does not return a non-zero exit code if the + # Darwin 8.11.1's |which| does not return a non-zero exit code if the # program can not be found. Therefore, kludge around it. findprogram() { @@ -170,14 +156,14 @@ if [[ -z "$LIBRARYSH" ]]; then } # loaddata - # + # # load data files into environment loaddata() { local datafiles="$@" local datafile if [[ -n "$datafiles" ]]; then - for datafile in $datafiles; do + for datafile in $datafiles; do if [[ ! -e "$datafile" ]]; then error "datafile $datafile does not exist" fi @@ -227,7 +213,7 @@ if [[ -z "$LIBRARYSH" ]]; then # dumpvars varname1, ... # - # dumps name=value pairs to stdout for each variable named + # dumps name=value pairs to stdout for each variable named # in argument list dumpvars() @@ -267,9 +253,6 @@ if [[ -z "$LIBRARYSH" ]]; then case "$OSID" in darwin) get_executable_filter="Contents/MacOS/$get_executable_product" - if [[ "$get_executable_product" == "thunderbird" ]]; then - get_executable_name="$get_executable_product-bin" - fi ;; *) get_executable_filter="$get_executable_product" @@ -286,7 +269,7 @@ if [[ -z "$LIBRARYSH" ]]; then error "get_executable $product $branch $executablepath returned empty path" $LINENO fi - if [[ ! -x "$executable" ]]; then + if [[ ! -x "$executable" ]]; then error "executable \"$executable\" is not executable" $LINENO fi diff --git a/testing/sisyphus/bin/set-build-env.sh b/testing/sisyphus/bin/set-build-env.sh index deef8646644d..b056877e1956 100755 --- a/testing/sisyphus/bin/set-build-env.sh +++ b/testing/sisyphus/bin/set-build-env.sh @@ -64,8 +64,8 @@ usage() usage: set-build-env.sh -p product -b branch -T buildtype [-e extra] --p product one of js firefox thunderbird fennec --b branch one of 1.8.0 1.8.1 1.9.0 1.9.1 1.9.2 +-p product one of js firefox. +-b branch one of supported branches. see library.sh -T buildtype one of opt debug -e extra extra qualifier to pick mozconfig and tree @@ -78,7 +78,7 @@ myexit() case $0 in *bash*) - # prevent "sourced" script calls from + # prevent "sourced" script calls from # exiting the current shell. break 99;; *) @@ -90,8 +90,8 @@ for step in step1; do # dummy loop for handling exits unset product branch buildtype extra - while getopts $options optname ; - do + while getopts $options optname ; + do case $optname in p) product=$OPTARG;; b) branch=$OPTARG;; @@ -130,8 +130,12 @@ for step in step1; do # dummy loop for handling exits elif [[ $branch == "1.9.0" ]]; then export BRANCH_CO_FLAGS=""; elif [[ $branch == "1.9.1" ]]; then + TEST_MOZILLA_HG=${TEST_MOZILLA_HG:-http://hg.mozilla.org/releases/mozilla-1.9.1} export BRANCH_CO_FLAGS=""; elif [[ $branch == "1.9.2" ]]; then + TEST_MOZILLA_HG=${TEST_MOZILLA_HG:-http://hg.mozilla.org/releases/mozilla-1.9.2} + export BRANCH_CO_FLAGS=""; + elif [[ $branch == "1.9.3" ]]; then TEST_MOZILLA_HG=${TEST_MOZILLA_HG:-http://hg.mozilla.org/mozilla-central} export BRANCH_CO_FLAGS=""; else @@ -227,8 +231,9 @@ for step in step1; do # dummy loop for handling exits startbat=start-msvc71.bat fi ;; - 1.9.0|1.9.1|1.9.2) + *) # msvc8 official, vc7.1, (2003), vc9 (2009) supported + # for 1.9.0 and later if [[ -n "$VC8DIR" ]]; then startbat=start-msvc8.bat # set VCINSTALLDIR for use in detecting the MS CRT @@ -316,7 +321,7 @@ for step in step1; do # dummy loop for handling exits export buildbash="/bin/bash" export bashlogin=-l - # if a 64 bit linux system, assume the + # if a 64 bit linux system, assume the # compiler is in the standard reference # location /tools/gcc/bin/ case "$TEST_PROCESSORTYPE" in @@ -339,16 +344,7 @@ for step in step1; do # dummy loop for handling exits export CONFIG_SHELL=$buildbash export CONFIGURE_ENV_ARGS=$buildbash - # note that thunderbird and fennec based on 1.9.1 can not be contained in the - # same tree as firefox since they come from different repositories. - case "$branch-$product" in - 1.9.1-thunderbird) - export BUILDTREE="${BUILDTREE:-$BUILDDIR/$branch-$product$extra}" - ;; - *) - export BUILDTREE="${BUILDTREE:-$BUILDDIR/$branch$extra}" - ;; - esac + export BUILDTREE="${BUILDTREE:-$BUILDDIR/$branch$extra}" # # extras can't be placed in mozconfigs since not all parts @@ -400,32 +396,14 @@ for step in step1; do # dummy loop for handling exits export TEST_MOZILLA_HG=${TEST_MOZILLA_HG:-http://hg.mozilla.org/releases/mozilla-1.9.1} ;; 1.9.2) + export TEST_MOZILLA_HG=${TEST_MOZILLA_HG:-http://hg.mozilla.org/releases/mozilla-1.9.2} + ;; + 1.9.3) export TEST_MOZILLA_HG=${TEST_MOZILLA_HG:-http://hg.mozilla.org/mozilla-central} ;; esac export MOZCONFIG=${MOZCONFIG:-"$BUILDTREE/mozconfig-firefox-$OSID-$TEST_PROCESSORTYPE-$buildtype"} - elif [[ $product == "thunderbird" ]]; then - project=mail - case $branch in - 1.8.*);; - 1.9.0);; - *) - export TEST_MOZILLA_HG=${TEST_MOZILLA_HG:-http://hg.mozilla.org/comm-central} - ;; - esac - export MOZCONFIG=${MOZCONFIG:-"$BUILDTREE/mozconfig-thunderbird-$OSID-$TEST_PROCESSORTYPE-$buildtype"} - elif [[ $product == "fennec" ]]; then - project=mobile - case $branch in - 1.9.1) - export TEST_MOZILLA_HG=${TEST_MOZILLA_HG:-http://hg.mozilla.org/releases/mozilla-1.9.1} - ;; - 1.9.2) - export TEST_MOZILLA_HG=${TEST_MOZILLA_HG:-http://hg.mozilla.org/mozilla-central} - ;; - esac - export MOZCONFIG=${MOZCONFIG:-"$BUILDTREE/mozconfig-fennec-$OSID-$TEST_PROCESSORTYPE-$buildtype"} else echo "Assuming project=browser for product: $product" project=browser @@ -434,6 +412,9 @@ for step in step1; do # dummy loop for handling exits export TEST_MOZILLA_HG=${TEST_MOZILLA_HG:-http://hg.mozilla.org/releases/mozilla-1.9.1} ;; 1.9.2) + export TEST_MOZILLA_HG=${TEST_MOZILLA_HG:-http://hg.mozilla.org/releases/mozilla-1.9.2} + ;; + 1.9.3) export TEST_MOZILLA_HG=${TEST_MOZILLA_HG:-http://hg.mozilla.org/mozilla-central} ;; esac @@ -471,31 +452,13 @@ for step in step1; do # dummy loop for handling exits js) jsshellsourcepath=${jsshellsourcepath:-$BUILDTREE/mozilla/js/src} ;; - thunderbird) - profilename=${profilename:-$product-$branch$extra-profile} - profiledirectory=${profiledirectory:-/tmp/$product-$branch$extra-profile} - userpreferences=${userpreferences:-$TEST_DIR/prefs/test-user.js} - extensiondir=${extensiondir:-$TEST_DIR/xpi} - if [[ $branch == "1.8.0" || $branch = "1.8.1" || $branch == "1.9.0" ]]; then - executablepath=${executablepath:-$BUILDTREE/mozilla/$product-$buildtype/dist} - else - executablepath=${executablepath:-$BUILDTREE/mozilla/$product-$buildtype/mozilla/dist} - fi - ;; - fennec) - profilename=${profilename:-$product-$branch$extra-profile} - profiledirectory=${profiledirectory:-/tmp/$product-$branch$extra-profile} - userpreferences=${userpreferences:-$TEST_DIR/prefs/test-user.js} - extensiondir=${extensiondir:-$TEST_DIR/xpi} - executablepath=${executablepath:-$BUILDTREE/mozilla/$product-$buildtype/mobile/dist} - ;; esac if [[ -n "$datafiles" && ! -e $datafiles ]]; then # if there is not already a data file for this configuration, create it # this will save this configuration for the tester.sh and other scripts # which use datafiles for passing configuration values. - + echo product=\${product:-$product} >> $datafiles echo branch=\${branch:-$branch} >> $datafiles echo buildtype=\${buildtype:-$buildtype} >> $datafiles @@ -518,4 +481,3 @@ for step in step1; do # dummy loop for handling exits echo "mozconfig: $MOZCONFIG" cat $MOZCONFIG | sed 's/^/mozconfig: /' done - diff --git a/testing/sisyphus/bin/smoke-build.sh b/testing/sisyphus/bin/smoke-build.sh deleted file mode 100755 index 340ce58a725d..000000000000 --- a/testing/sisyphus/bin/smoke-build.sh +++ /dev/null @@ -1,96 +0,0 @@ -#!/bin/bash -e -# ***** BEGIN LICENSE BLOCK ***** -# Version: MPL 1.1/GPL 2.0/LGPL 2.1 -# -# The contents of this file are subject to the Mozilla Public License Version -# 1.1 (the "License"); you may not use this file except in compliance with -# the License. You may obtain a copy of the License at -# http://www.mozilla.org/MPL/ -# -# Software distributed under the License is distributed on an "AS IS" basis, -# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License -# for the specific language governing rights and limitations under the -# License. -# -# The Original Code is mozilla.org code. -# -# The Initial Developer of the Original Code is -# Mozilla Corporation. -# Portions created by the Initial Developer are Copyright (C) 2006. -# the Initial Developer. All Rights Reserved. -# -# Contributor(s): -# Bob Clary -# -# Alternatively, the contents of this file may be used under the terms of -# either the GNU General Public License Version 2 or later (the "GPL"), or -# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), -# in which case the provisions of the GPL or the LGPL are applicable instead -# of those above. If you wish to allow use of your version of this file only -# under the terms of either the GPL or the LGPL, and not to allow others to -# use your version of this file under the terms of the MPL, indicate your -# decision by deleting the provisions above and replace them with the notice -# and other provisions required by the GPL or the LGPL. If you do not delete -# the provisions above, a recipient may use your version of this file under -# the terms of any one of the MPL, the GPL or the LGPL. -# -# ***** END LICENSE BLOCK ***** - -source $TEST_DIR/bin/library.sh - -if [[ -z "$1" ]]; then - echo smoke-build.sh directorypattern - exit 1 -fi - -for filepath in $@; do - echo $filepath - - base=`basename $filepath` - - version=`echo $base|sed 's/[^0-9.]*\([0-9]*\).*/\1/'` - product=`echo $base|sed 's/\([^-]*\)-.*/\1/'` - - case $version in - 1) branch=1.8.0;; - 2) branch=1.8.1;; - 3) branch=1.9.0;; - esac - - echo $product $branch - - if ! install-build.sh -p "$product" -b "$branch" -x "/tmp/$product-$branch" \ - -f "$filepath"; then - error "installing build $product $branch into /tmp/$product-$branch" $LINENO - fi - - if [[ "$product" == "thunderbird" ]]; then - template="-L ${TEST_DIR}/profiles/imap" - else - unset template - fi - - if ! create-profile.sh -p "$product" -b "$branch" \ - -x "/tmp/$product-$branch" \ - -D "/tmp/$product-$branch-profile" -N "$product-$branch-profile" \ - -U ${TEST_DIR}/prefs/test-user.js \ - $template; then - error "creating profile $product-$branch-profile at /tmp/$product-$branch" $LINENO - fi - - if ! install-extensions.sh -p "$product" -b "$branch" \ - -x "/tmp/$product-$branch" \ - -N "$product-$branch-profile" \ - -E ${TEST_DIR}/xpi; then - error "installing extensions from ${TEST_DIR}/xpi" $LINENO - fi - - if ! check-spider.sh -p "$product" -b "$branch" \ - -x "/tmp/$product-$branch" \ - -N "$product-$branch-profile"; then - error "check-spider.sh failed." $LINENO - fi - - uninstall-build.sh -p "$product" -b "$branch" -x "/tmp/$product-$branch" - -done diff --git a/testing/sisyphus/bin/spider.pl b/testing/sisyphus/bin/spider.pl deleted file mode 100755 index a86f0fffd026..000000000000 --- a/testing/sisyphus/bin/spider.pl +++ /dev/null @@ -1,255 +0,0 @@ -#!/usr/bin/perl -# -*- Mode: Perl; tab-width: 4; indent-tabs-mode: nil; -*- -# ***** BEGIN LICENSE BLOCK ***** -# Version: MPL 1.1/GPL 2.0/LGPL 2.1 -# -# The contents of this file are subject to the Mozilla Public License Version -# 1.1 (the "License"); you may not use this file except in compliance with -# the License. You may obtain a copy of the License at -# http://www.mozilla.org/MPL/ -# -# Software distributed under the License is distributed on an "AS IS" basis, -# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License -# for the specific language governing rights and limitations under the -# License. -# -# The Original Code is Mozilla Automated Testing Code -# -# The Initial Developer of the Original Code is -# Mozilla Corporation. -# Portions created by the Initial Developer are Copyright (C) 2005 -# the Initial Developer. All Rights Reserved. -# -# Contributor(s): Bob Clary -# -# Alternatively, the contents of this file may be used under the terms of -# either the GNU General Public License Version 2 or later (the "GPL"), or -# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), -# in which case the provisions of the GPL or the LGPL are applicable instead -# of those above. If you wish to allow use of your version of this file only -# under the terms of either the GPL or the LGPL, and not to allow others to -# use your version of this file under the terms of the MPL, indicate your -# decision by deleting the provisions above and replace them with the notice -# and other provisions required by the GPL or the LGPL. If you do not delete -# the provisions above, a recipient may use your version of this file under -# the terms of any one of the MPL, the GPL or the LGPL. -# -# ***** END LICENSE BLOCK ***** - -# make unbuffered -select STDERR; $| = 1; -select STDOUT; $| = 1; - -use File::Temp qw/ tempfile tempdir /; -use File::Basename; -use Getopt::Mixed "nextOption"; -use URI::Escape; -use Time::HiRes qw(sleep); - -my $DEBUG = 0; - -my $product = ""; -my $executable = ""; -my $profile = ""; -my $url = ""; -my $domain = ""; -my $depth = 0; -my $timeout = 0; -my $wait = 0; -my $hook = ""; -my $start = "off"; -my $quit = "off"; -my $robot = "off"; -my $debug = "off"; -my $jserrors = "off"; -my $jswarnings = "off"; -my $chromeerrors = "off"; -my $xblerrors = "off"; -my $csserrors = "off"; - -parse_options(); - -my $hookon = ($hook ? "on" : "off"); -my $runtime = dirname($executable); - -chdir $runtime or - die "spider.pl: unable to change directory to runtime $runtime"; - - -my $chromeurl; - -my $testUrl; - -my $spider = "chrome://spider/content/spider.xul?" . - "domain=$domain&" . - "depth=$depth&" . - "timeout=$timeout" . - "&waittime=$wait&" . - "autostart=$start&" . - "autoquit=$quit&" . - "javascripterrors=$jserrors&" . - "javascriptwarnings=$jswarnings&" . - "chromeerrors=$chromeerrors&" . - "xblerrors=$xblerrors&" . - "csserrors=$csserrors&" . - "hooksignal=$hookon&" . - "url=" . uri_escape(uri_escape($url)); - -if ($hook) -{ - $spider .= "&scripturl=" . uri_escape($hook); -} - -my @args; -my $rc; -my $signal; -my $dumped; - -if ($product eq "thunderbird") -{ - @args = ($executable, "-P", $profile, $spider); -} -else -{ - @args = ($executable, "-P", $profile, "-chrome", $spider); -} - -system @args; -$rc = $? >> 8; - -if ($rc == 99) -{ - exit $rc; -} - -sub usage -{ - my $arg = shift @_; - my $value = shift @_; - - print <