Mercurial > hg
changeset 4234:fe0c0a317c09
make the output of test-locate more readable
author | Alexis S. L. Carvalho <alexis@cecm.usp.br> |
---|---|
date | Fri, 16 Mar 2007 22:48:21 -0300 |
parents | 03a665f9f913 |
children | eca3277c4220 |
files | tests/test-locate tests/test-locate.out |
diffstat | 2 files changed, 46 insertions(+), 13 deletions(-) [+] |
line wrap: on
line diff
--- a/tests/test-locate Fri Mar 16 22:48:20 2007 -0300 +++ b/tests/test-locate Fri Mar 16 22:48:21 2007 -0300 @@ -1,5 +1,14 @@ #!/bin/sh -# + +hglocate() +{ + echo "hg locate $@" + hg locate "$@" + ret=$? + echo + return $ret +} + mkdir t cd t hg init @@ -10,22 +19,22 @@ echo 0 > t/x hg ci -A -m m -d "1000000 0" touch nottracked -hg locate a && echo locate succeeded || echo locate failed -hg locate NONEXISTENT && echo locate succeeded || echo locate failed -hg locate +hglocate a && echo locate succeeded || echo locate failed +hglocate NONEXISTENT && echo locate succeeded || echo locate failed +hglocate hg rm a hg ci -m m -d "1000000 0" -hg locate a -hg locate NONEXISTENT -hg locate -hg locate -r 0 a -hg locate -r 0 NONEXISTENT -hg locate -r 0 +hglocate a +hglocate NONEXISTENT +hglocate +hglocate -r 0 a +hglocate -r 0 NONEXISTENT +hglocate -r 0 echo % -I/-X with relative path should work cd t -hg locate -hg locate -I ../t +hglocate +hglocate -I ../t # test issue294 cd .. rm -r t -hg locate t +hglocate t
--- a/tests/test-locate.out Fri Mar 16 22:48:20 2007 -0300 +++ b/tests/test-locate.out Fri Mar 16 22:48:21 2007 -0300 @@ -2,24 +2,48 @@ adding b adding t.h adding t/x +hg locate a a + locate succeeded +hg locate NONEXISTENT + locate failed +hg locate a b t.h t/x + +hg locate a + +hg locate NONEXISTENT + +hg locate b t.h t/x + +hg locate -r 0 a a + +hg locate -r 0 NONEXISTENT + +hg locate -r 0 a b t.h t/x + % -I/-X with relative path should work +hg locate b t.h t/x + +hg locate -I ../t t/x + +hg locate t t/x +