Mercurial > hg
diff tests/test-rebase-obsolete.t @ 34092:8a8e7a94ba07
rebase: do not crash rebasing merge with a parent having hidden successor
The added test will crash with previous code.
Differential Revision: https://phab.mercurial-scm.org/D640
author | Jun Wu <quark@fb.com> |
---|---|
date | Wed, 06 Sep 2017 12:40:00 -0700 |
parents | e8a7c1a0565a |
children | 15ec3119d500 |
line wrap: on
line diff
--- a/tests/test-rebase-obsolete.t Wed Sep 06 18:33:55 2017 -0700 +++ b/tests/test-rebase-obsolete.t Wed Sep 06 12:40:00 2017 -0700 @@ -1267,3 +1267,37 @@ |/ o A +Rebasing a merge with one of its parent having a hidden successor + + $ hg init $TESTTMP/merge-p1-hidden-successor + $ cd $TESTTMP/merge-p1-hidden-successor + + $ hg debugdrawdag <<'EOS' + > E + > | + > B3 B2 # amend: B1 -> B2 -> B3 + > |/ # B2 is hidden + > | D + > | |\ + > | B1 C + > |/ + > A + > EOS + + $ eval `hg tags -T '{tag}={node}\n'` + $ rm .hg/localtags + + $ hg rebase -r $D -d $E + rebasing 5:9e62094e4d94 "D" + + $ hg log -G + o 7:a699d059adcf D + |\ + | o 6:ecc93090a95c E + | | + | o 4:0dc878468a23 B3 + | | + o | 1:96cc3511f894 C + / + o 0:426bada5c675 A +