Mercurial > hg-git
changeset 471:e8302d9c3ef0
tests: fix for hg 1.5.4
On Hg 1.5.4, util.version() appears to return "unknown", which wasn't an
expected value in the version parsing logic in test-incoming and test-outgoing.
The net result of the change is that test-incoming no longer fails in 1.5.4,
but is skipped instead.
author | David M. Carr <david@carrclan.us> |
---|---|
date | Sat, 04 Aug 2012 14:43:48 -0400 |
parents | 493b55cb7362 |
children | 64fd6107cf05 |
files | tests/test-incoming tests/test-outgoing |
diffstat | 2 files changed, 4 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/tests/test-incoming Sat Aug 04 14:06:19 2012 -0400 +++ b/tests/test-incoming Sat Aug 04 14:43:48 2012 -0400 @@ -7,7 +7,8 @@ python -c 'import dulwich, dulwich.repo' || exit 80 # This test only works on hg 1.7 and later -python -c 'from mercurial import util ; assert util.version() > "1.7"' || exit 80 +python -c 'from mercurial import util ; assert \ + util.version() != "unknown" and util.version() > "1.7"' || exit 80 # bail early if the user is already running git-daemon echo hi | nc localhost 9418 2>/dev/null && exit 80
--- a/tests/test-outgoing Sat Aug 04 14:06:19 2012 -0400 +++ b/tests/test-outgoing Sat Aug 04 14:43:48 2012 -0400 @@ -7,7 +7,8 @@ # Fails for some reason, need to investigate # "$TESTDIR/hghave" git || exit 80 -python -c 'from mercurial import util ; assert util.version() < "1.8"' || exit 80 +python -c 'from mercurial import util ; assert \ + util.version() == "unknown" or util.version() < "1.8"' || exit 80 # bail if the user does not have dulwich python -c 'import dulwich, dulwich.repo' || exit 80