--- a/tests/test-locate.out
+++ b/tests/test-locate.out
@@ -1,5 +1,6 @@
adding a
adding b
+adding dir.h/foo
adding t.h
adding t/b
adding t/e.h
@@ -14,6 +15,7 @@ locate failed
hg locate
a
b
+dir.h/foo
t.h
t/b
t/e.h
@@ -25,6 +27,7 @@ hg locate NONEXISTENT
hg locate
b
+dir.h/foo
t.h
t/b
t/e.h
@@ -38,6 +41,7 @@ hg locate -r 0 NONEXISTENT
hg locate -r 0
a
b
+dir.h/foo
t.h
t/b
t/e.h
@@ -46,6 +50,7 @@ t/x
% -I/-X with relative path should work
hg locate
b
+dir.h/foo
t.h
t/b
t/e.h
@@ -56,7 +61,7 @@ t/b
t/e.h
t/x
-hg locate t
+hg locate t/**
t/b
t/e.h
t/x
@@ -72,7 +77,7 @@ hg locate *.h
hg locate path:t/x
../t/x
-hg locate re:.*\.h
+hg locate re:.*\.h$
../t.h
../t/e.h
@@ -87,7 +92,7 @@ hg locate -r 0 *.h
hg locate -r 0 path:t/x
../t/x
-hg locate -r 0 re:.*\.h
+hg locate -r 0 re:.*\.h$
../t.h
../t/e.h