зеркало из https://github.com/mozilla/gecko-dev.git
Since we have frozen the tip I only checked in high priority fixes.
The individual fixes: 1) A complete QA failure produces a readable email now 2) the nssqa has goes thru a central Exit 3) hanging processes under NT and Win2K are killed (tail -f) 4) Functionallity is implemented to kill other remaining processes (killpif file) 5) improved general cleanup in Exit functions 6) the header is sourced from the nssqa dir rateher than /u/sonmi/bin 7) Problems with QA being reported as passed even if missing fixed 8) Most problems with the "missing Platform list" fixed 9) One QA failure path (cd to a dir without permission) did not give errormessage about the reason of failure before 10) fixed html errors in generated email 11) stopped filtering the "bad password" cases as real failures (was fixed in nssqa a while ago, but still filtered 12) removing more tmp files from /tmp (decreased debugging)
This commit is contained in:
Родитель
74241c3ef8
Коммит
7c1970ee45
|
@ -119,6 +119,10 @@ then
|
|||
exit 1
|
||||
fi
|
||||
|
||||
KILLPIDS="$TMP/killpids.$$"
|
||||
export KILLERPIDS
|
||||
TMPFILES="$TMPFILES $KILLPIDS"
|
||||
|
||||
KILL_SELFSERV=OFF # if sourcing script sets this to on cleanup will also
|
||||
# kill the running selfserv processes
|
||||
|
||||
|
@ -153,6 +157,9 @@ then # want the init to wait forever for directories to
|
|||
WIN_WAIT_FOREVER=OFF
|
||||
fi
|
||||
|
||||
EARLY_EXIT=TRUE #before the report file has been created, causes Exit to
|
||||
#create it
|
||||
|
||||
################################### glob_init ##########################
|
||||
# global shell function, main initialisation function
|
||||
########################################################################
|
||||
|
@ -636,6 +643,36 @@ kill_by_name()
|
|||
done
|
||||
}
|
||||
|
||||
############################### early_exit ###################################
|
||||
# global shell function , attempts a little more usefull user notification
|
||||
# of a complete failure
|
||||
########################################################################
|
||||
|
||||
early_exit()
|
||||
{
|
||||
if [ -z "$DOCDIR" ]
|
||||
then
|
||||
DOCDIR=`dirname $0`/../doc
|
||||
fi
|
||||
if [ -f $DOCDIR/QAerror.html ]
|
||||
then
|
||||
Debug "Found QA errorheader"
|
||||
rm ${FILENAME}.err 2>/dev/null
|
||||
cp $DOCDIR/QAerror.html ${FILENAME}.err
|
||||
echo "$1" >>${FILENAME}.err
|
||||
echo '</font></b></h1>' >>${FILENAME}.err
|
||||
if [ -n "$FILENAME" -a -f "$FILENAME" ]
|
||||
then
|
||||
cat $FILENAME | sed -e "s/^/<br>/" >>${FILENAME}.err
|
||||
fi
|
||||
echo '</body></html>' >>${FILENAME}.err
|
||||
cat ${FILENAME}.err | rmail $MAILINGLIST
|
||||
|
||||
rm ${FILENAME}.err 2>/dev/null
|
||||
#echo "cat ${FILENAME}.err | rmail $MAILINGLIST "
|
||||
fi
|
||||
}
|
||||
|
||||
############################### Exit ###################################
|
||||
# global shell function , central exiting point
|
||||
# cleanup: temporary files, kill the remaining selfservers if sourcing
|
||||
|
@ -648,6 +685,13 @@ Exit()
|
|||
then
|
||||
echo $1 >&2
|
||||
fi
|
||||
if [ -f "${KILLPIDS}" ]
|
||||
then
|
||||
Debug "Attempting to kill background processes...`cat ${KILLPIDS}`"
|
||||
kill `cat "${KILLPIDS}"`
|
||||
sleep 1
|
||||
kill -9 `cat "${KILLPIDS}"`
|
||||
fi
|
||||
if [ -n "${TMPFILES}" ]
|
||||
then
|
||||
Debug "rm -f ${TMPFILES}"
|
||||
|
@ -660,7 +704,18 @@ Exit()
|
|||
fi
|
||||
if [ $O_MAIL = "ON" -a $O_FILE = "ON" ]
|
||||
then
|
||||
cat $FILENAME | rmail $MAILINGLIST
|
||||
if [ $EARLY_EXIT = TRUE ] #before the report file has been created
|
||||
then
|
||||
early_exit "$1"
|
||||
elif [ -n "$FILENAME" -a -f "$FILENAME" ]
|
||||
then
|
||||
cat $FILENAME | rmail $MAILINGLIST
|
||||
fi
|
||||
rm $FILENAME 2>/dev/null
|
||||
elif [ $O_MAIL = "ON" -a $EARLY_EXIT = TRUE ]
|
||||
then
|
||||
early_exit "$1"
|
||||
rm $FILENAME 2>/dev/null
|
||||
fi
|
||||
#chmod a+rw ${RESULTDIR} ${RESULTDIR}/* ${RESULTDIR}/*/* &
|
||||
exit
|
||||
|
@ -910,7 +965,7 @@ glob_usage()
|
|||
Echo " $0 31 1002"
|
||||
opt_usage
|
||||
Echo
|
||||
Exit
|
||||
Exit "$1"
|
||||
}
|
||||
|
||||
tell()
|
||||
|
@ -974,3 +1029,4 @@ if [ $O_INIT = "ON" ]
|
|||
then
|
||||
glob_init $*
|
||||
fi
|
||||
EARLY_EXIT=FALSE
|
||||
|
|
|
@ -230,7 +230,7 @@ case `uname -s` in
|
|||
Debug "Copy results from $NT_MASTERDIR/mozilla/tests_results/security to $RESULTDIR"
|
||||
cp -r $NT_MASTERDIR/mozilla/tests_results/security/* $RESULTDIR
|
||||
fi
|
||||
Exit "Done."
|
||||
return
|
||||
;;
|
||||
esac
|
||||
|
||||
|
@ -247,7 +247,6 @@ else
|
|||
Debug "This is a 32 bit platform"
|
||||
fi
|
||||
|
||||
Exit "Done."
|
||||
}
|
||||
|
||||
if [ $O_FILE = ON ]
|
||||
|
@ -257,3 +256,4 @@ else
|
|||
nssqa_main
|
||||
fi
|
||||
|
||||
Exit "Done."
|
||||
|
|
|
@ -27,7 +27,9 @@
|
|||
|
||||
O_OPTIONS=ON
|
||||
|
||||
. /u/sonmi/bin/header
|
||||
. `dirname $0`/header
|
||||
|
||||
EARLY_EXIT=TRUE
|
||||
|
||||
DOCDIR=/u/sonmi/doc
|
||||
|
||||
|
@ -41,7 +43,15 @@ Debug "RESULTDIR $RESULTDIR"
|
|||
########################################################################
|
||||
find_qa_systems()
|
||||
{
|
||||
for w in `ls $RESULTDIR | grep \. | sed -e "s/\..*//" | sort -u`
|
||||
|
||||
#the line below had a bug, which caused nssqa as being run when only
|
||||
#the .nssqa file existed
|
||||
#FIXME remaining bugs:
|
||||
#when only debug but not opt is being run this is not recognized.
|
||||
#2000 and NT are reported the same way
|
||||
#it should also examine the directory (.1) for files
|
||||
|
||||
for w in `ls $RESULTDIR | grep \.1$ | sed -e "s/\..*//" | sort -u`
|
||||
do
|
||||
NO_RSH="FALSE"
|
||||
QA_OS=""
|
||||
|
@ -116,6 +126,10 @@ set_files()
|
|||
#doesn't seem to work - this is a tmp workaround
|
||||
fi
|
||||
|
||||
if [ ! -x $RESULTDIR -o ! -r $RESULTDIR -o ! -w $RESULTDIR ]
|
||||
then
|
||||
glob_usage "$RESULTDIR does not have the right permissions `ls -l $RESULTDIR`"
|
||||
fi
|
||||
if [ -d $RESULTDIR ]
|
||||
then
|
||||
cd $RESULTDIR
|
||||
|
@ -265,8 +279,9 @@ qa_errorlist()
|
|||
lline
|
||||
fi
|
||||
|
||||
#FIXME - take bad password out!!!!
|
||||
grep red */results.html | grep -v 'bad password' |
|
||||
#FIXME it should also examine the files for passed messages, since
|
||||
#sometimes empty results and output.log files are generated
|
||||
grep red */results.html |
|
||||
sed -e 's/.results.html:<TR><TD>/ /' -e 's/<[^>]*>/ /g'
|
||||
if [ "$1" = "1" ]
|
||||
then
|
||||
|
@ -439,5 +454,6 @@ qa_errorlist 2 | sed -e "s/^/<br>/" >>$HTML_FILE
|
|||
|
||||
html_footer >>$HTML_FILE
|
||||
|
||||
EARLY_EXIT=FALSE
|
||||
FILENAME=$HTML_FILE #we might want to mail it...
|
||||
Exit
|
||||
|
|
Загрузка…
Ссылка в новой задаче