author | Adrian Buehlmann <adrian@cadifra.com> |
Wed, 23 Mar 2011 11:22:29 +0100 | |
changeset 13743 | 2d53cefb44e3 |
parent 12399 | 4fee1fd3de9a |
child 13956 | ffb5c09ba822 |
permissions | -rw-r--r-- |
12206
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
1 |
$ mkdir t |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
2 |
$ cd t |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
3 |
$ hg init |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
4 |
$ echo 0 > a |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
5 |
$ echo 0 > b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
6 |
$ echo 0 > t.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
7 |
$ mkdir t |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
8 |
$ echo 0 > t/x |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
9 |
$ echo 0 > t/b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
10 |
$ echo 0 > t/e.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
11 |
$ mkdir dir.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
12 |
$ echo 0 > dir.h/foo |
4234
fe0c0a317c09
make the output of test-locate more readable
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
4196
diff
changeset
|
13 |
|
12206
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
14 |
$ hg ci -A -m m |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
15 |
adding a |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
16 |
adding b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
17 |
adding dir.h/foo |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
18 |
adding t.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
19 |
adding t/b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
20 |
adding t/e.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
21 |
adding t/x |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
22 |
|
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
23 |
$ touch nottracked |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
24 |
|
12365
22f3353bcc36
tests: cleanup exit code handling in unified tests
Matt Mackall <mpm@selenic.com>
parents:
12316
diff
changeset
|
25 |
$ hg locate a |
12206
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
26 |
a |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
27 |
|
12365
22f3353bcc36
tests: cleanup exit code handling in unified tests
Matt Mackall <mpm@selenic.com>
parents:
12316
diff
changeset
|
28 |
$ hg locate NONEXISTENT |
22f3353bcc36
tests: cleanup exit code handling in unified tests
Matt Mackall <mpm@selenic.com>
parents:
12316
diff
changeset
|
29 |
[1] |
12206
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
30 |
|
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
31 |
$ hg locate |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
32 |
a |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
33 |
b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
34 |
dir.h/foo |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
35 |
t.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
36 |
t/b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
37 |
t/e.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
38 |
t/x |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
39 |
|
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
40 |
$ hg rm a |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
41 |
$ hg ci -m m |
4234
fe0c0a317c09
make the output of test-locate more readable
Alexis S. L. Carvalho <alexis@cecm.usp.br>
parents:
4196
diff
changeset
|
42 |
|
12206
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
43 |
$ hg locate a |
12316
4134686b83e1
tests: add exit codes to unified tests
Matt Mackall <mpm@selenic.com>
parents:
12206
diff
changeset
|
44 |
[1] |
12206
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
45 |
$ hg locate NONEXISTENT |
12316
4134686b83e1
tests: add exit codes to unified tests
Matt Mackall <mpm@selenic.com>
parents:
12206
diff
changeset
|
46 |
[1] |
12206
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
47 |
$ hg locate relpath:NONEXISTENT |
12316
4134686b83e1
tests: add exit codes to unified tests
Matt Mackall <mpm@selenic.com>
parents:
12206
diff
changeset
|
48 |
[1] |
12206
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
49 |
$ hg locate |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
50 |
b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
51 |
dir.h/foo |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
52 |
t.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
53 |
t/b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
54 |
t/e.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
55 |
t/x |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
56 |
$ hg locate -r 0 a |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
57 |
a |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
58 |
$ hg locate -r 0 NONEXISTENT |
12316
4134686b83e1
tests: add exit codes to unified tests
Matt Mackall <mpm@selenic.com>
parents:
12206
diff
changeset
|
59 |
[1] |
12206
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
60 |
$ hg locate -r 0 relpath:NONEXISTENT |
12316
4134686b83e1
tests: add exit codes to unified tests
Matt Mackall <mpm@selenic.com>
parents:
12206
diff
changeset
|
61 |
[1] |
12206
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
62 |
$ hg locate -r 0 |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
63 |
a |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
64 |
b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
65 |
dir.h/foo |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
66 |
t.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
67 |
t/b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
68 |
t/e.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
69 |
t/x |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
70 |
|
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
71 |
-I/-X with relative path should work: |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
72 |
|
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
73 |
$ cd t |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
74 |
$ hg locate |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
75 |
b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
76 |
dir.h/foo |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
77 |
t.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
78 |
t/b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
79 |
t/e.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
80 |
t/x |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
81 |
$ hg locate -I ../t |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
82 |
t/b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
83 |
t/e.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
84 |
t/x |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
85 |
|
12399
4fee1fd3de9a
tests: added a short description to issue numbers
Martin Geisler <mg@aragost.com>
parents:
12365
diff
changeset
|
86 |
Issue294: hg remove --after dir fails when dir.* also exists |
12206
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
87 |
|
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
88 |
$ cd .. |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
89 |
$ rm -r t |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
90 |
|
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
91 |
$ hg locate 't/**' |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
92 |
t/b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
93 |
t/e.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
94 |
t/x |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
95 |
|
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
96 |
$ mkdir otherdir |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
97 |
$ cd otherdir |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
98 |
|
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
99 |
$ hg locate b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
100 |
../b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
101 |
../t/b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
102 |
$ hg locate '*.h' |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
103 |
../t.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
104 |
../t/e.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
105 |
$ hg locate path:t/x |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
106 |
../t/x |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
107 |
$ hg locate 're:.*\.h$' |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
108 |
../t.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
109 |
../t/e.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
110 |
$ hg locate -r 0 b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
111 |
../b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
112 |
../t/b |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
113 |
$ hg locate -r 0 '*.h' |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
114 |
../t.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
115 |
../t/e.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
116 |
$ hg locate -r 0 path:t/x |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
117 |
../t/x |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
118 |
$ hg locate -r 0 're:.*\.h$' |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
119 |
../t.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
120 |
../t/e.h |
844d25bf65a3
tests: unify test-locate
Adrian Buehlmann <adrian@cadifra.com>
parents:
12156
diff
changeset
|
121 |