Mercurial > evolve
annotate tests/test-evolve-content-divergent-first-changeset.t @ 6889:a66cf9008781
obslog: also display patch for rebased changesets
This applies the same logic that is used for "merge-diff" to rebased
changesets. The successors' content is compared to the content of the
predecessors rebased in-memory on the new parents.
This highlights the changes that were actually introduced while rebasing (like
conflict resolution or API adjustment).
As a side effect, obslog now also outputs slightly more diffs for splits,
showing what parts of the original big changeset were moved to the smaller
split components (but for now it only works for the first few changesets).
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Sun, 22 Sep 2024 02:58:54 +0200 |
parents | 83ceafbaa7d6 |
children | 88f9bbba392d |
rev | line source |
---|---|
4984
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
1 $ . $TESTDIR/testlib/pythonpath.sh |
5079
1f92a6aa40d6
evolve: add pre-check logic for content-divergence in rewriteutil.precheck()
Sushil khanchi <sushilkhanchi97@gmail.com>
parents:
4984
diff
changeset
|
2 $ cat >> $HGRCPATH << EOF |
1f92a6aa40d6
evolve: add pre-check logic for content-divergence in rewriteutil.precheck()
Sushil khanchi <sushilkhanchi97@gmail.com>
parents:
4984
diff
changeset
|
3 > [extensions] |
1f92a6aa40d6
evolve: add pre-check logic for content-divergence in rewriteutil.precheck()
Sushil khanchi <sushilkhanchi97@gmail.com>
parents:
4984
diff
changeset
|
4 > evolve= |
1f92a6aa40d6
evolve: add pre-check logic for content-divergence in rewriteutil.precheck()
Sushil khanchi <sushilkhanchi97@gmail.com>
parents:
4984
diff
changeset
|
5 > [experimental] |
1f92a6aa40d6
evolve: add pre-check logic for content-divergence in rewriteutil.precheck()
Sushil khanchi <sushilkhanchi97@gmail.com>
parents:
4984
diff
changeset
|
6 > evolution.allowdivergence = True |
1f92a6aa40d6
evolve: add pre-check logic for content-divergence in rewriteutil.precheck()
Sushil khanchi <sushilkhanchi97@gmail.com>
parents:
4984
diff
changeset
|
7 > EOF |
1f92a6aa40d6
evolve: add pre-check logic for content-divergence in rewriteutil.precheck()
Sushil khanchi <sushilkhanchi97@gmail.com>
parents:
4984
diff
changeset
|
8 |
4984
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
9 This test file tests the case of content-divergence resolution of changesets |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
10 that have the null revision as the parent. |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
11 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
12 $ hg init issue6201 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
13 $ cd issue6201 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
14 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
15 $ touch test |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
16 $ hg add test |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
17 $ hg commit -m test |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
18 $ hg log -T '{node|short}\n' |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
19 be090ea66256 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
20 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
21 $ echo a >> test |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
22 $ hg amend -m div1 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
23 $ hg log -T '{node|short}\n' |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
24 79fa0eb22d65 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
25 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
26 $ hg up be090ea66256 --hidden --quiet |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
27 updated to hidden changeset be090ea66256 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
28 (hidden revision 'be090ea66256' was rewritten as: 79fa0eb22d65) |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
29 working directory parent is obsolete! (be090ea66256) |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
30 $ echo a >> test |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
31 $ echo b >> test |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
32 $ hg amend -m div2 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
33 2 new content-divergent changesets |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
34 $ hg log -T '{node|short}\n' |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
35 4b2524b7508e |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
36 79fa0eb22d65 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
37 |
5084
946ebd8f08ea
tests: use --tool flag instead of --config ui.merge
Anton Shestakov <av6@dwimlabs.net>
parents:
4984
diff
changeset
|
38 $ hg evolve --content-divergent --tool :other |
4984
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
39 merge:[1] div1 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
40 with: [2] div2 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
41 base: [0] test |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
42 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
5297
a73cdef2e33f
evolve: rename `evolve_source_*` to `divergence_source_*`
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
5293
diff
changeset
|
43 working directory is now at 62fcb3488421 |
4984
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
44 |
b779b40f996e
evolve: fix content-divergence resolution when p1 is null (issue6201)
Manuel Jacob <me@manueljacob.de>
parents:
diff
changeset
|
45 $ hg evolve --list |