Mercurial > hg
annotate tests/test-inotify-dirty-dirstate @ 11715:4f9dfb54c8b5 stable
qpush --move: move the right patch even with comment lines
88fc876a4833 caused that we find the index of the moving patch in self.series
but look it up in self.full_series. The difference between these is that
full_series also contains comment lines, and we thus moved the wrong patch.
Use back self.full_series to find the moving patch, but take care of striping
the patch guard markers before comparing the patch name. Test cases have been
added for comments and empty lines in self.full_series, and for the case of
guarded patches.
Original patch contributed by Mads Kiilerich <mads@kiilerich.com>
author | Gilles Moris <gilles.moris@free.fr> |
---|---|
date | Sat, 10 Jul 2010 21:23:00 +0200 |
parents | 97eda2133a9b |
children |
rev | line source |
---|---|
9855
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
1 #!/bin/sh |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
2 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
3 # issues when status queries are issued when dirstate is dirty |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
4 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
5 "$TESTDIR/hghave" inotify || exit 80 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
6 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
7 echo "[extensions]" >> $HGRCPATH |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
8 echo "inotify=" >> $HGRCPATH |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
9 echo "fetch=" >> $HGRCPATH |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
10 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
11 echo % issue1810: inotify and fetch |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
12 mkdir test; cd test |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
13 hg init |
9859
951ec6c7d703
inotify: workaround test-inotify-dirty-dirstate failures
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
9855
diff
changeset
|
14 hg inserve -d --pid-file=../hg.pid |
951ec6c7d703
inotify: workaround test-inotify-dirty-dirstate failures
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
9855
diff
changeset
|
15 cat ../hg.pid >> "$DAEMON_PIDS" |
9855
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
16 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
17 echo foo > foo |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
18 hg add |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
19 hg ci -m foo |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
20 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
21 cd .. |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
22 |
9897
97eda2133a9b
inotify: add a inotify.pidfile configuration possibility
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
9859
diff
changeset
|
23 hg --config "inotify.pidfile=../hg2.pid" clone test test2 |
97eda2133a9b
inotify: add a inotify.pidfile configuration possibility
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
9859
diff
changeset
|
24 cat ../hg2.pid >> "$DAEMON_PIDS" |
97eda2133a9b
inotify: add a inotify.pidfile configuration possibility
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
9859
diff
changeset
|
25 |
9855
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
26 cd test2 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
27 echo bar > bar |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
28 hg add |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
29 hg ci -m bar |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
30 cd ../test |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
31 echo spam > spam |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
32 hg add |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
33 hg ci -m spam |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
34 cd ../test2 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
35 hg st |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
36 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
37 # abort, outstanding changes |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
38 hg fetch -q |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
39 hg st |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
40 cd .. |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
41 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
42 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
43 echo % issue1719: inotify and mq |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
44 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
45 echo "mq=" >> $HGRCPATH |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
46 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
47 hg init test-1719 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
48 cd test-1719 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
49 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
50 echo % inserve |
9859
951ec6c7d703
inotify: workaround test-inotify-dirty-dirstate failures
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
9855
diff
changeset
|
51 hg inserve -d --pid-file=../hg-test-1719.pid |
951ec6c7d703
inotify: workaround test-inotify-dirty-dirstate failures
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
9855
diff
changeset
|
52 cat ../hg-test-1719.pid >> "$DAEMON_PIDS" |
9855
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
53 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
54 echo content > file |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
55 hg add file |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
56 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
57 hg qnew -f test.patch |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
58 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
59 hg status |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
60 hg qpop |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
61 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
62 echo % st should not output anything |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
63 hg status |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
64 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
65 hg qpush |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
66 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
67 echo % st should not output anything |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
68 hg status |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
69 |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
70 hg qrefresh |
f47c0881b16e
inotify: Do not access inotify when dirstate is dirty (issue1811)
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents:
diff
changeset
|
71 hg status |