Mercurial > hg
view tests/test-check-commit.t @ 49446:8c75ae3f0eea stable
tests: remove flakiness in test-nointerrupt.t
The problem was that the reaction to the signal was racing against
the completion of the command.
Since reaction to the signal is to print a line of warning,
we can fix this by waiting for that warning to appear before
allowing the command to complete.
author | Arseniy Alekseyev <aalekseyev@janestreet.com> |
---|---|
date | Fri, 26 Aug 2022 11:36:20 +0100 |
parents | 33817e09c663 |
children |
line wrap: on
line source
#require test-repo Enable obsolescence to avoid the warning issue when obsmarker are found $ . "$TESTDIR/helpers-testrepo.sh" Go back in the hg repo $ cd $TESTDIR/.. $ REVSET='not public() and ::. and not desc("# no-check-commit")' $ mkdir "$TESTTMP/p" $ REVS=`testrepohg log -r "$REVSET" -T.` $ if [ -n "$REVS" ] ; then > testrepohg export --git -o "$TESTTMP/p/%n-%h" -r "$REVSET" > for f in `ls "$TESTTMP/p"`; do > contrib/check-commit < "$TESTTMP/p/$f" > "$TESTTMP/check-commit.out" > if [ $? -ne 0 ]; then > node="${f##*-}" > echo "Revision $node does not comply with rules" > echo '------------------------------------------------------' > cat ${TESTTMP}/check-commit.out > echo > fi > done > fi