Mercurial > hg
annotate tests/test-dirstate-status-write-race.t @ 50220:35ea3c139104 stable
dirstate: cover each dirstate version when testing for status race
Previously we were only testing it with the default (dirstate-v1 currently).
Now we explicitly test each variant.
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Fri, 24 Feb 2023 01:15:45 +0100 |
parents | 72104dd91f2b |
children | ecd28d89c29e |
rev | line source |
---|---|
50215
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
1 ===================================================================== |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
2 Check potential race conditions between a status and other operations |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
3 ===================================================================== |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
4 |
50220
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
5 #testcases dirstate-v1 dirstate-v2 |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
6 |
50215
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
7 The `hg status` command can run without the wlock, however it might end up |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
8 having to update the on-disk dirstate files, for example to mark ambiguous |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
9 files as clean, or to update directory caches information with dirstate-v2. |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
10 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
11 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
12 If another process updates the dirstate in the meantime we might run into |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
13 trouble. Especially, commands doing semantic changes like `hg add` or |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
14 `hg commit` should not see their update erased by a concurrent status. |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
15 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
16 Unlike commands like `add` or `commit`, `status` only writes the dirstate |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
17 to update caches, no actual information is lost if we fail to write to disk. |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
18 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
19 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
20 This test file is meant to test various cases where such parallel operations |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
21 between a status with reasons to update the dirstate and another semantic |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
22 changes happen. |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
23 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
24 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
25 Setup |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
26 ===== |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
27 |
50220
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
28 $ cat >> $HGRCPATH << EOF |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
29 > [storage] |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
30 > dirstate-v2.slow-path=allow |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
31 > EOF |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
32 |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
33 #if dirstate-v2 |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
34 $ cat >> $HGRCPATH << EOF |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
35 > [format] |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
36 > use-dirstate-v2=yes |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
37 > EOF |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
38 #else |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
39 $ cat >> $HGRCPATH << EOF |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
40 > [format] |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
41 > use-dirstate-v2=no |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
42 > EOF |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
43 #endif |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
44 |
50215
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
45 $ directories="dir dir/nested dir2" |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
46 $ first_files="dir/nested/a dir/b dir/c dir/d dir2/e f" |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
47 $ second_files="g dir/nested/h dir/i dir/j dir2/k dir2/l dir/nested/m" |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
48 $ extra_files="dir/n dir/o p q" |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
49 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
50 $ hg init reference-repo |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
51 $ cd reference-repo |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
52 $ mkdir -p dir/nested dir2 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
53 $ touch -t 200001010000 $first_files $directories |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
54 $ hg commit -Aqm "recreate a bunch of files to facilitate dirstate-v2 append" |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
55 $ touch -t 200001010010 $second_files $directories |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
56 $ hg commit -Aqm "more files to have two commits" |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
57 $ hg log -G -v |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
58 @ changeset: 1:c349430a1631 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
59 | tag: tip |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
60 | user: test |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
61 | date: Thu Jan 01 00:00:00 1970 +0000 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
62 | files: dir/i dir/j dir/nested/h dir/nested/m dir2/k dir2/l g |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
63 | description: |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
64 | more files to have two commits |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
65 | |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
66 | |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
67 o changeset: 0:4f23db756b09 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
68 user: test |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
69 date: Thu Jan 01 00:00:00 1970 +0000 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
70 files: dir/b dir/c dir/d dir/nested/a dir2/e f |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
71 description: |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
72 recreate a bunch of files to facilitate dirstate-v2 append |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
73 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
74 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
75 $ hg manifest |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
76 dir/b |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
77 dir/c |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
78 dir/d |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
79 dir/i |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
80 dir/j |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
81 dir/nested/a |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
82 dir/nested/h |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
83 dir/nested/m |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
84 dir2/e |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
85 dir2/k |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
86 dir2/l |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
87 f |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
88 g |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
89 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
90 Add some unknown files and refresh the dirstate |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
91 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
92 $ touch -t 200001010020 $extra_files |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
93 $ hg add dir/o |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
94 $ hg remove dir/nested/m |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
95 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
96 $ hg st |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
97 A dir/o |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
98 R dir/nested/m |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
99 ? dir/n |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
100 ? p |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
101 ? q |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
102 $ hg debugstate |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
103 n 644 0 2000-01-01 00:00:00 dir/b |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
104 n 644 0 2000-01-01 00:00:00 dir/c |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
105 n 644 0 2000-01-01 00:00:00 dir/d |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
106 n 644 0 2000-01-01 00:10:00 dir/i |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
107 n 644 0 2000-01-01 00:10:00 dir/j |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
108 n 644 0 2000-01-01 00:00:00 dir/nested/a |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
109 n 644 0 2000-01-01 00:10:00 dir/nested/h |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
110 r ?????????????????????????????????? dir/nested/m (glob) |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
111 a ?????????????????????????????????? dir/o (glob) |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
112 n 644 0 2000-01-01 00:00:00 dir2/e |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
113 n 644 0 2000-01-01 00:10:00 dir2/k |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
114 n 644 0 2000-01-01 00:10:00 dir2/l |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
115 n 644 0 2000-01-01 00:00:00 f |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
116 n 644 0 2000-01-01 00:10:00 g |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
117 $ hg debugstate > ../reference |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
118 $ cd .. |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
119 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
120 Explain / verify the test principles |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
121 ------------------------------------ |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
122 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
123 First, we can properly copy the reference |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
124 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
125 $ cp -a reference-repo sanity-check |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
126 $ cd sanity-check |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
127 $ hg debugstate |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
128 n 644 0 2000-01-01 00:00:00 dir/b |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
129 n 644 0 2000-01-01 00:00:00 dir/c |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
130 n 644 0 2000-01-01 00:00:00 dir/d |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
131 n 644 0 2000-01-01 00:10:00 dir/i |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
132 n 644 0 2000-01-01 00:10:00 dir/j |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
133 n 644 0 2000-01-01 00:00:00 dir/nested/a |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
134 n 644 0 2000-01-01 00:10:00 dir/nested/h |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
135 r ?????????????????????????????????? dir/nested/m (glob) |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
136 a ?????????????????????????????????? dir/o (glob) |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
137 n 644 0 2000-01-01 00:00:00 dir2/e |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
138 n 644 0 2000-01-01 00:10:00 dir2/k |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
139 n 644 0 2000-01-01 00:10:00 dir2/l |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
140 n 644 0 2000-01-01 00:00:00 f |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
141 n 644 0 2000-01-01 00:10:00 g |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
142 $ hg debugstate > ../post-copy |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
143 $ diff ../reference ../post-copy |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
144 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
145 And status thinks the cache is in a proper state |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
146 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
147 $ hg st |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
148 A dir/o |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
149 R dir/nested/m |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
150 ? dir/n |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
151 ? p |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
152 ? q |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
153 $ hg debugstate |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
154 n 644 0 2000-01-01 00:00:00 dir/b |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
155 n 644 0 2000-01-01 00:00:00 dir/c |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
156 n 644 0 2000-01-01 00:00:00 dir/d |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
157 n 644 0 2000-01-01 00:10:00 dir/i |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
158 n 644 0 2000-01-01 00:10:00 dir/j |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
159 n 644 0 2000-01-01 00:00:00 dir/nested/a |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
160 n 644 0 2000-01-01 00:10:00 dir/nested/h |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
161 r ?????????????????????????????????? dir/nested/m (glob) |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
162 a ?????????????????????????????????? dir/o (glob) |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
163 n 644 0 2000-01-01 00:00:00 dir2/e |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
164 n 644 0 2000-01-01 00:10:00 dir2/k |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
165 n 644 0 2000-01-01 00:10:00 dir2/l |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
166 n 644 0 2000-01-01 00:00:00 f |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
167 n 644 0 2000-01-01 00:10:00 g |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
168 $ hg debugstate > ../post-status |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
169 $ diff ../reference ../post-status |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
170 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
171 Then we can start a status that: |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
172 - has some update to do (the touch call) |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
173 - will wait AFTER running status, but before updating the cache on disk |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
174 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
175 $ touch -t 200001010001 dir/c |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
176 $ hg st >$TESTTMP/status-race-lock.out 2>$TESTTMP/status-race-lock.log \ |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
177 > --config rhg.on-unsupported=abort \ |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
178 > --config devel.sync.status.pre-dirstate-write-file=$TESTTMP/status-race-lock \ |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
179 > & |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
180 $ $RUNTESTDIR/testlib/wait-on-file 5 $TESTTMP/status-race-lock.waiting |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
181 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
182 We check it runs the status first by modifying a file and updating another timestamp |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
183 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
184 $ touch -t 200001010003 dir/i |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
185 $ echo babar > dir/j |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
186 $ touch $TESTTMP/status-race-lock |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
187 $ wait |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
188 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
189 The test process should have reported a status before the change we made, |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
190 and should have missed the timestamp update |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
191 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
192 $ cat $TESTTMP/status-race-lock.out |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
193 A dir/o |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
194 R dir/nested/m |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
195 ? dir/n |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
196 ? p |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
197 ? q |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
198 $ cat $TESTTMP/status-race-lock.log |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
199 $ hg debugstate | grep dir/c |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
200 n 644 0 2000-01-01 00:01:00 dir/c |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
201 $ hg debugstate | grep dir/i |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
202 n 644 0 2000-01-01 00:10:00 dir/i |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
203 $ hg debugstate | grep dir/j |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
204 n 644 0 2000-01-01 00:10:00 dir/j |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
205 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
206 final cleanup |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
207 |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
208 $ rm $TESTTMP/status-race-lock $TESTTMP/status-race-lock.waiting |
ae61851e6fe2
dirstate: add a way to test races happening during status
Raphaël Gomès <rgomes@octobus.net>, Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
209 $ cd .. |
50216
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
210 |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
211 Actual Testing |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
212 ============== |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
213 |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
214 Race with a `hg add` |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
215 ------------------- |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
216 |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
217 $ cp -a reference-repo race-with-add |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
218 $ cd race-with-add |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
219 |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
220 spin a `hg status` with some caches to update |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
221 |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
222 $ touch -t 200001020001 f |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
223 $ hg st >$TESTTMP/status-race-lock.out 2>$TESTTMP/status-race-lock.log \ |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
224 > --config rhg.on-unsupported=abort \ |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
225 > --config devel.sync.status.pre-dirstate-write-file=$TESTTMP/status-race-lock \ |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
226 > & |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
227 $ $RUNTESTDIR/testlib/wait-on-file 5 $TESTTMP/status-race-lock.waiting |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
228 |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
229 Add a file |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
230 |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
231 $ hg add dir/n |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
232 $ touch $TESTTMP/status-race-lock |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
233 $ wait |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
234 |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
235 The file should in a "added" state |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
236 |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
237 $ hg status |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
238 A dir/n (no-rhg !) |
50220
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
239 A dir/n (rhg no-dirstate-v1 !) |
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
240 A dir/n (missing-correct-output rhg dirstate-v1 !) |
50216
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
241 A dir/o |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
242 R dir/nested/m |
50220
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
243 ? dir/n (known-bad-output rhg dirstate-v1 !) |
50216
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
244 ? p |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
245 ? q |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
246 |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
247 The status process should return a consistent result and not crash. |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
248 |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
249 $ cat $TESTTMP/status-race-lock.out |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
250 A dir/o |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
251 R dir/nested/m |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
252 ? dir/n |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
253 ? p |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
254 ? q |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
255 $ cat $TESTTMP/status-race-lock.log |
50220
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
256 abort: when writing $TESTTMP/race-with-add/.hg/dirstate.*: $ENOENT$ (glob) (known-bad-output rhg dirstate-v2 !) |
50216
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
257 |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
258 final cleanup |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
259 |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
260 $ rm $TESTTMP/status-race-lock $TESTTMP/status-race-lock.waiting |
02bf2f94a04c
dirstate: test a `hg status` raced by a `hg add`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50215
diff
changeset
|
261 $ cd .. |
50217
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
262 |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
263 Race with a `hg commit` |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
264 ---------------------- |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
265 |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
266 $ cp -a reference-repo race-with-commit |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
267 $ cd race-with-commit |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
268 |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
269 spin a `hg status` with some caches to update |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
270 |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
271 $ touch -t 200001020001 dir/j |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
272 $ hg st >$TESTTMP/status-race-lock.out 2>$TESTTMP/status-race-lock.log \ |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
273 > --config rhg.on-unsupported=abort \ |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
274 > --config devel.sync.status.pre-dirstate-write-file=$TESTTMP/status-race-lock \ |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
275 > & |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
276 $ $RUNTESTDIR/testlib/wait-on-file 5 $TESTTMP/status-race-lock.waiting |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
277 |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
278 Add a file and force the data file rewrite |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
279 |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
280 $ hg commit -m created-during-status dir/o |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
281 $ touch $TESTTMP/status-race-lock |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
282 $ wait |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
283 |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
284 The parent must change and the status should be clean |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
285 |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
286 # XXX rhg misbehaves here |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
287 #if no-rhg |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
288 $ hg summary |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
289 parent: 2:2e3b442a2fd4 tip |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
290 created-during-status |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
291 branch: default |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
292 commit: 1 removed, 3 unknown |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
293 update: (current) |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
294 phases: 3 draft |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
295 $ hg status |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
296 R dir/nested/m |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
297 ? dir/n |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
298 ? p |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
299 ? q |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
300 #else |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
301 $ hg summary |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
302 parent: 1:c349430a1631 |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
303 more files to have two commits |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
304 branch: default |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
305 commit: 1 added, 1 removed, 3 unknown (new branch head) |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
306 update: 1 new changesets (update) |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
307 phases: 3 draft |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
308 $ hg status |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
309 A dir/o |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
310 R dir/nested/m |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
311 ? dir/n |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
312 ? p |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
313 ? q |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
314 #endif |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
315 |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
316 The status process should return a consistent result and not crash. |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
317 |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
318 $ cat $TESTTMP/status-race-lock.out |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
319 A dir/o |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
320 R dir/nested/m |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
321 ? dir/n |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
322 ? p |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
323 ? q |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
324 $ cat $TESTTMP/status-race-lock.log |
50220
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
325 abort: when removing $TESTTMP/race-with-commit/.hg/dirstate.*: $ENOENT$ (glob) (known-bad-output rhg dirstate-v2 !) |
50217
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
326 |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
327 final cleanup |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
328 |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
329 $ rm $TESTTMP/status-race-lock $TESTTMP/status-race-lock.waiting |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
330 $ cd .. |
718fcccae326
dirstate: test a `hg status` raced by a `hg commit`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50216
diff
changeset
|
331 |
50218
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
332 Race with a `hg update` |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
333 ---------------------- |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
334 |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
335 $ cp -a reference-repo race-with-update |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
336 $ cd race-with-update |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
337 |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
338 spin a `hg status` with some caches to update |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
339 |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
340 $ touch -t 200001020001 dir2/k |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
341 $ hg st >$TESTTMP/status-race-lock.out 2>$TESTTMP/status-race-lock.log \ |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
342 > --config rhg.on-unsupported=abort \ |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
343 > --config devel.sync.status.pre-dirstate-write-file=$TESTTMP/status-race-lock \ |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
344 > & |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
345 $ $RUNTESTDIR/testlib/wait-on-file 5 $TESTTMP/status-race-lock.waiting |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
346 |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
347 Add a file and force the data file rewrite |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
348 |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
349 $ hg update ".~1" |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
350 0 files updated, 0 files merged, 6 files removed, 0 files unresolved |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
351 $ touch $TESTTMP/status-race-lock |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
352 $ wait |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
353 |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
354 The parent must change and the status should be clean |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
355 |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
356 $ hg summary |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
357 parent: 0:4f23db756b09 |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
358 recreate a bunch of files to facilitate dirstate-v2 append |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
359 branch: default |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
360 commit: 1 added, 3 unknown (new branch head) |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
361 update: 1 new changesets (update) |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
362 phases: 2 draft |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
363 $ hg status |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
364 A dir/o |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
365 ? dir/n |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
366 ? p |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
367 ? q |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
368 |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
369 The status process should return a consistent result and not crash. |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
370 |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
371 $ cat $TESTTMP/status-race-lock.out |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
372 A dir/o |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
373 R dir/nested/m |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
374 ? dir/n |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
375 ? p |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
376 ? q |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
377 $ cat $TESTTMP/status-race-lock.log |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
378 abort: when reading $TESTTMP/race-with-update/dir2/k: $ENOENT$ (known-bad-output rhg !) |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
379 |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
380 final cleanup |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
381 |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
382 $ rm $TESTTMP/status-race-lock $TESTTMP/status-race-lock.waiting |
ee75dd844ab6
dirstate: test a `hg status` raced by a `hg update`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50217
diff
changeset
|
383 $ cd .. |
50219
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
384 |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
385 Race with another status |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
386 ------------------------ |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
387 |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
388 $ cp -a reference-repo race-with-status |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
389 $ cd race-with-status |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
390 |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
391 spin a `hg status` with some caches to update |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
392 |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
393 $ touch -t 200001010030 dir/nested/h |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
394 $ hg st >$TESTTMP/status-race-lock.out 2>$TESTTMP/status-race-lock.log \ |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
395 > --config rhg.on-unsupported=abort \ |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
396 > --config devel.sync.status.pre-dirstate-write-file=$TESTTMP/status-race-lock \ |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
397 > & |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
398 $ $RUNTESTDIR/testlib/wait-on-file 5 $TESTTMP/status-race-lock.waiting |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
399 |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
400 touch g |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
401 |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
402 $ touch -t 200001010025 g |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
403 $ hg status |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
404 A dir/o |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
405 R dir/nested/m |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
406 ? dir/n |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
407 ? p |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
408 ? q |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
409 $ touch $TESTTMP/status-race-lock |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
410 $ wait |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
411 |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
412 the first update should be on disk |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
413 |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
414 $ hg debugstate --all | grep "g" |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
415 n 644 0 2000-01-01 00:25:00 g (no-rhg !) |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
416 n 644 0 2000-01-01 00:25:00 g (missing-correct-output rhg !) |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
417 n 644 0 2000-01-01 00:10:00 g (known-bad-output rhg !) |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
418 |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
419 The status process should return a consistent result and not crash. |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
420 |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
421 $ cat $TESTTMP/status-race-lock.out |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
422 A dir/o |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
423 R dir/nested/m |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
424 ? dir/n |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
425 ? p |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
426 ? q |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
427 $ cat $TESTTMP/status-race-lock.log |
50220
35ea3c139104
dirstate: cover each dirstate version when testing for status race
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50219
diff
changeset
|
428 abort: when removing $TESTTMP/race-with-status/.hg/dirstate.*: $ENOENT$ (glob) (known-bad-output rhg dirstate-v2 !) |
50219
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
429 |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
430 final cleanup |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
431 |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
432 $ rm $TESTTMP/status-race-lock $TESTTMP/status-race-lock.waiting |
72104dd91f2b
dirstate: test a `hg status` raced by another `hg status`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
50218
diff
changeset
|
433 $ cd .. |