Mercurial > hg > mercurial-crew-with-dirclash
annotate tests/test-convert-darcs @ 5483:0c43f87baba3 default tip
Fix file-changed-to-dir and dir-to-file commits (issue660).
Allow adding to dirstate files that clash with previously existing
but marked for removal. Protect from reintroducing clashes by revert.
This change doesn't address related issues with update. Current
workaround is to do "clean" update by manually removing conflicting
files/dirs from working directory.
author | Maxim Dounin <mdounin@mdounin.ru> |
---|---|
date | Sat, 27 Oct 2007 16:27:55 +0400 |
parents | a19167001251 |
children |
rev | line source |
---|---|
5413 | 1 #!/bin/sh |
2 | |
3 "$TESTDIR/hghave" darcs || exit 80 | |
4 | |
5 echo "[extensions]" >> $HGRCPATH | |
6 echo "convert=" >> $HGRCPATH | |
7 echo 'hgext.graphlog =' >> $HGRCPATH | |
8 | |
9 DARCS_EMAIL='test@example.org'; export DARCS_EMAIL | |
5438
a19167001251
test-convert-darcs: don't let $HOME/.darcs pollute the test environment
Bryan O'Sullivan <bos@serpentine.com>
parents:
5413
diff
changeset
|
10 HOME=do_not_use_HOME_darcs; export HOME |
5413 | 11 |
12 echo % initialize darcs repo | |
13 mkdir darcs-repo | |
14 cd darcs-repo | |
15 darcs init | |
16 echo a > a | |
17 darcs record -a -l -m p0 | |
18 cd .. | |
19 | |
20 echo % branch and update | |
21 darcs get darcs-repo darcs-clone | |
22 cd darcs-clone | |
23 echo c >> a | |
24 echo c > c | |
25 darcs record -a -l -m p1.1 | |
26 cd .. | |
27 | |
28 echo % update source | |
29 cd darcs-repo | |
30 echo b >> a | |
31 echo b > b | |
32 darcs record -a -l -m p1.2 | |
33 | |
34 echo % merge branch | |
35 darcs pull -a ../darcs-clone | |
36 echo e > a | |
37 darcs record -a -l -m p2 | |
38 cd .. | |
39 | |
40 glog() | |
41 { | |
42 hg glog --template '#rev# "#desc|firstline#" files: #files#\n' "$@" | |
43 } | |
44 | |
45 hg convert darcs-repo darcs-repo-hg | |
46 # The converter does not currently handle patch conflicts very well. | |
47 # When they occur, it reverts *all* changes and moves forward, | |
48 # letting the conflict resolving patch fix collisions. | |
49 # Unfortunately, non-conflicting changes, like the addition of the | |
50 # "c" file in p1.1 patch are reverted too. | |
51 # Just to say that manifest not listing "c" here is a bug. | |
52 glog -R darcs-repo-hg | |
53 hg -R darcs-repo-hg manifest --debug |