Mercurial > hg
changeset 12785:c7d23b4ca4ba
check-code: warning and fixes for whitespace in unified tests
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Wed, 20 Oct 2010 14:57:36 -0500 |
parents | 763be3cd084a |
children | 9aae04f4fcf6 |
files | contrib/check-code.py tests/test-convert-cvs-branch.t tests/test-push-warn.t tests/test-rebase-mq-skip.t |
diffstat | 4 files changed, 5 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/contrib/check-code.py Wed Oct 20 20:19:34 2010 +0200 +++ b/contrib/check-code.py Wed Oct 20 14:57:36 2010 -0500 @@ -74,6 +74,7 @@ uprefix = r"^ \$ " uprefixc = r"^ > " utestpats = [ + (r'^(\S| $ ).*(\S\s+|^\s+)\n', "trailing whitespace on non-output"), (uprefix + r'.*\|\s*sed', "use regex test output patterns instead of sed"), (uprefix + r'(true|exit 0)', "explicit zero exit unnecessary"), (uprefix + r'.*\$\?', "explicit exit code checks unnecessary"),
--- a/tests/test-convert-cvs-branch.t Wed Oct 20 20:19:34 2010 +0200 +++ b/tests/test-convert-cvs-branch.t Wed Oct 20 14:57:36 2010 -0500 @@ -42,7 +42,7 @@ $ cvscall up -r BRANCH > /dev/null cvs update: Updating . -Modify file a, then b, then a +Modify file a, then b, then a $ sleep 1 $ echo "2" > a
--- a/tests/test-push-warn.t Wed Oct 20 20:19:34 2010 +0200 +++ b/tests/test-push-warn.t Wed Oct 20 14:57:36 2010 -0500 @@ -336,7 +336,7 @@ added 1 changesets with 1 changes to 1 files -Checking prepush logic does not allow silently pushing +Checking prepush logic does not allow silently pushing multiple new heads: $ cd .. @@ -480,7 +480,7 @@ $ hg ci -Ama2 adding a2 -a2 is now the new branch head of A, and a new topological head +a2 is now the new branch head of A, and a new topological head it replaces a former inner branch head, so it should at most warn about A, not B
--- a/tests/test-rebase-mq-skip.t Wed Oct 20 20:19:34 2010 +0200 +++ b/tests/test-rebase-mq-skip.t Wed Oct 20 14:57:36 2010 -0500 @@ -1,4 +1,4 @@ -This emulates the effects of an hg pull --rebase in which the remote repo +This emulates the effects of an hg pull --rebase in which the remote repo already has one local mq patch $ cat >> $HGRCPATH <<EOF