comparison tests/test-evolve-content-divergent-basic.t @ 5297:a73cdef2e33f

evolve: rename `evolve_source_*` to `divergence_source_*` This makes it clearer that this comes from divergence resolution.
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Fri, 08 May 2020 04:02:22 +0200
parents 142827ad86f3
children e8660b28bfee
comparison
equal deleted inserted replaced
5296:142827ad86f3 5297:a73cdef2e33f
140 $ hg evolve --all --any --content-divergent 140 $ hg evolve --all --any --content-divergent
141 merge:[2] divergent 141 merge:[2] divergent
142 with: [3] divergent 142 with: [3] divergent
143 base: [1] added b 143 base: [1] added b
144 1 files updated, 0 files merged, 0 files removed, 0 files unresolved 144 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
145 working directory is now at cfcd9a3d0588 145 working directory is now at 98ab969ac8fb
146 $ hg log -G 146 $ hg log -G
147 @ 4:cfcd9a3d0588@default(draft) divergent [] 147 @ 4:98ab969ac8fb@default(draft) divergent []
148 | 148 |
149 o 0:9092f1db7931@default(draft) added a [] 149 o 0:9092f1db7931@default(draft) added a []
150 150
151 $ hg export 151 $ hg export
152 # HG changeset patch 152 # HG changeset patch
153 # User test 153 # User test
154 # Date 0 0 154 # Date 0 0
155 # Thu Jan 01 00:00:00 1970 +0000 155 # Thu Jan 01 00:00:00 1970 +0000
156 # Node ID cfcd9a3d0588dd3abd278373246f2bdd6a646647 156 # Node ID 98ab969ac8fbe315e6d2c24a8eb5eab5b81e4242
157 # Parent 9092f1db7931481f93b37d5c9fbcfc341bcd7318 157 # Parent 9092f1db7931481f93b37d5c9fbcfc341bcd7318
158 divergent 158 divergent
159 159
160 diff --git a/bdivergent1 b/bdivergent1 160 diff --git a/bdivergent1 b/bdivergent1
161 new file mode 100644 161 new file mode 100644
238 with: [5] added d 238 with: [5] added d
239 base: [4] added d 239 base: [4] added d
240 0 files updated, 0 files merged, 0 files removed, 0 files unresolved 240 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
241 content divergent changesets on different branches. 241 content divergent changesets on different branches.
242 choose branch for the resolution changeset. (a) default or (b) watwat or (c) foobar? c 242 choose branch for the resolution changeset. (a) default or (b) watwat or (c) foobar? c
243 working directory is now at f7d7ae0f2678 243 working directory is now at 15ee7f765bf7
244 244
245 $ hg glog 245 $ hg glog
246 @ 7:f7d7ae0f2678 added d 246 @ 7:15ee7f765bf7 added d
247 | () [foobar] draft 247 | () [foobar] draft
248 o 3:ca1b80f7960a added c 248 o 3:ca1b80f7960a added c
249 | () [default] draft 249 | () [default] draft
250 o 2:b1661037fa25 added b 250 o 2:b1661037fa25 added b
251 | () [default] draft 251 | () [default] draft
274 2 new content-divergent changesets 274 2 new content-divergent changesets
275 275
276 $ hg glog 276 $ hg glog
277 @ 9:59081c9c425a added a d with bar in it, expect some beers 277 @ 9:59081c9c425a added a d with bar in it, expect some beers
278 | () [default] draft 278 | () [default] draft
279 | * 8:41db48ee7fab added d 279 | * 8:e6f07f2f33a9 added d
280 |/ () [foobar] draft 280 |/ () [foobar] draft
281 o 3:ca1b80f7960a added c 281 o 3:ca1b80f7960a added c
282 | () [default] draft 282 | () [default] draft
283 o 2:b1661037fa25 added b 283 o 2:b1661037fa25 added b
284 | () [default] draft 284 | () [default] draft
290 $ hg evolve --content-divergent --no-all 290 $ hg evolve --content-divergent --no-all
291 merge:[9] added a d with bar in it, expect some beers 291 merge:[9] added a d with bar in it, expect some beers
292 with: [8] added d 292 with: [8] added d
293 base: [7] added d 293 base: [7] added d
294 1 files updated, 0 files merged, 0 files removed, 0 files unresolved 294 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
295 working directory is now at 687b947d0a60 295 working directory is now at 34e78e1673c1
296 296
297 $ hg glog 297 $ hg glog
298 @ 10:687b947d0a60 added a d with bar in it, expect some beers 298 @ 10:34e78e1673c1 added a d with bar in it, expect some beers
299 | () [default] draft 299 | () [default] draft
300 o 3:ca1b80f7960a added c 300 o 3:ca1b80f7960a added c
301 | () [default] draft 301 | () [default] draft
302 o 2:b1661037fa25 added b 302 o 2:b1661037fa25 added b
303 | () [default] draft 303 | () [default] draft
311 $ echo foo > d 311 $ echo foo > d
312 $ hg amend -m "foo to d" 312 $ hg amend -m "foo to d"
313 313
314 $ hg up 'predecessors(.)' --hidden 314 $ hg up 'predecessors(.)' --hidden
315 1 files updated, 0 files merged, 0 files removed, 0 files unresolved 315 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
316 updated to hidden changeset 687b947d0a60 316 updated to hidden changeset 34e78e1673c1
317 (hidden revision '687b947d0a60' was rewritten as: 7b36e4bdcf1b) 317 (hidden revision '34e78e1673c1' was rewritten as: c9d0d72972b0)
318 working directory parent is obsolete! (687b947d0a60) 318 working directory parent is obsolete! (34e78e1673c1)
319 (use 'hg evolve' to update to its successor: 7b36e4bdcf1b) 319 (use 'hg evolve' to update to its successor: c9d0d72972b0)
320 $ echo babar > d 320 $ echo babar > d
321 $ hg amend -m "foo to d" 321 $ hg amend -m "foo to d"
322 2 new content-divergent changesets 322 2 new content-divergent changesets
323 323
324 $ hg glog 324 $ hg glog
325 @ 12:9de05413bc4d foo to d 325 @ 12:b4dadb3b47a7 foo to d
326 | () [default] draft 326 | () [default] draft
327 | * 11:7b36e4bdcf1b foo to d 327 | * 11:c9d0d72972b0 foo to d
328 |/ () [default] draft 328 |/ () [default] draft
329 o 3:ca1b80f7960a added c 329 o 3:ca1b80f7960a added c
330 | () [default] draft 330 | () [default] draft
331 o 2:b1661037fa25 added b 331 o 2:b1661037fa25 added b
332 | () [default] draft 332 | () [default] draft
349 $ echo foobar > d 349 $ echo foobar > d
350 $ hg resolve -m 350 $ hg resolve -m
351 (no more unresolved files) 351 (no more unresolved files)
352 continue: hg evolve --continue 352 continue: hg evolve --continue
353 $ hg evolve --continue 353 $ hg evolve --continue
354 working directory is now at 348265c659d9 354 working directory is now at cfd599de811a
355 355
356 $ hg glog 356 $ hg glog
357 @ 13:348265c659d9 foo to d 357 @ 13:cfd599de811a foo to d
358 | () [default] draft 358 | () [default] draft
359 o 3:ca1b80f7960a added c 359 o 3:ca1b80f7960a added c
360 | () [default] draft 360 | () [default] draft
361 o 2:b1661037fa25 added b 361 o 2:b1661037fa25 added b
362 | () [default] draft 362 | () [default] draft
371 $ echo bar > d 371 $ echo bar > d
372 $ hg amend -m "bar to d, expect beers" 372 $ hg amend -m "bar to d, expect beers"
373 373
374 $ hg up 'predecessors(.)' --hidden 374 $ hg up 'predecessors(.)' --hidden
375 1 files updated, 0 files merged, 0 files removed, 0 files unresolved 375 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
376 updated to hidden changeset 348265c659d9 376 updated to hidden changeset cfd599de811a
377 (hidden revision '348265c659d9' was rewritten as: e0633eb64c66) 377 (hidden revision 'cfd599de811a' was rewritten as: ba0941ffb747)
378 working directory parent is obsolete! (348265c659d9) 378 working directory parent is obsolete! (cfd599de811a)
379 (use 'hg evolve' to update to its successor: e0633eb64c66) 379 (use 'hg evolve' to update to its successor: ba0941ffb747)
380 $ echo wat > d 380 $ echo wat > d
381 $ hg amend -m "wat to d, wat?" 381 $ hg amend -m "wat to d, wat?"
382 2 new content-divergent changesets 382 2 new content-divergent changesets
383 383
384 $ hg glog 384 $ hg glog
385 @ 15:3eec13f9b72e wat to d, wat? 385 @ 15:4127dd63df67 wat to d, wat?
386 | () [default] draft 386 | () [default] draft
387 | * 14:e0633eb64c66 bar to d, expect beers 387 | * 14:ba0941ffb747 bar to d, expect beers
388 |/ () [default] draft 388 |/ () [default] draft
389 o 3:ca1b80f7960a added c 389 o 3:ca1b80f7960a added c
390 | () [default] draft 390 | () [default] draft
391 o 2:b1661037fa25 added b 391 o 2:b1661037fa25 added b
392 | () [default] draft 392 | () [default] draft
432 foo to d======= 432 foo to d=======
433 bar to d, expect beers>>>>>>> other 433 bar to d, expect beers>>>>>>> other
434 434
435 **done showing editors text** 435 **done showing editors text**
436 436
437 working directory is now at 39483e49e3bb 437 working directory is now at b4c8664fa327
438 438
439 $ hg glog 439 $ hg glog
440 @ 16:39483e49e3bb watbar to d 440 @ 16:b4c8664fa327 watbar to d
441 | () [default] draft 441 | () [default] draft
442 o 3:ca1b80f7960a added c 442 o 3:ca1b80f7960a added c
443 | () [default] draft 443 | () [default] draft
444 o 2:b1661037fa25 added b 444 o 2:b1661037fa25 added b
445 | () [default] draft 445 | () [default] draft
531 0 files updated, 1 files merged, 0 files removed, 0 files unresolved 531 0 files updated, 1 files merged, 0 files removed, 0 files unresolved
532 committing files: 532 committing files:
533 a 533 a
534 committing manifest 534 committing manifest
535 committing changelog 535 committing changelog
536 working directory is now at b4deda8116ef 536 working directory is now at 6aa6f90a9f68
537 $ hg st 537 $ hg st
538 $ glog 538 $ glog
539 @ 4:b4deda8116ef@default(draft) bk:[] More addition 539 @ 4:6aa6f90a9f68@default(draft) bk:[] More addition
540 | 540 |
541 o 0:6569b5a81c7e@default(public) bk:[] root 541 o 0:6569b5a81c7e@default(public) bk:[] root
542 542
543 $ hg summary 543 $ hg summary
544 parent: 4:b4deda8116ef tip 544 parent: 4:6aa6f90a9f68 tip
545 More addition 545 More addition
546 branch: default 546 branch: default
547 commit: (clean) 547 commit: (clean)
548 update: (current) 548 update: (current)
549 phases: 1 draft 549 phases: 1 draft
550 $ hg export . --config diff.unified=3 550 $ hg export . --config diff.unified=3
551 # HG changeset patch 551 # HG changeset patch
552 # User test 552 # User test
553 # Date 0 0 553 # Date 0 0
554 # Thu Jan 01 00:00:00 1970 +0000 554 # Thu Jan 01 00:00:00 1970 +0000
555 # Node ID b4deda8116effeb6eeabd0a14f40cc8b21ca1b37 555 # Node ID 6aa6f90a9f684b8a4b698234e25c5dad7328b199
556 # Parent 6569b5a81c7e307ddc076550e8c0f6d75b6effcd 556 # Parent 6569b5a81c7e307ddc076550e8c0f6d75b6effcd
557 More addition 557 More addition
558 558
559 diff --git a/a b/a 559 diff --git a/a b/a
560 --- a/a 560 --- a/a
575 575
576 576
577 $ hg up --hidden 'min(desc("More addition"))' 577 $ hg up --hidden 'min(desc("More addition"))'
578 1 files updated, 0 files merged, 0 files removed, 0 files unresolved 578 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
579 updated to hidden changeset 867e43582046 579 updated to hidden changeset 867e43582046
580 (hidden revision '867e43582046' was rewritten as: b4deda8116ef) 580 (hidden revision '867e43582046' was rewritten as: 6aa6f90a9f68)
581 working directory parent is obsolete! (867e43582046) 581 working directory parent is obsolete! (867e43582046)
582 (use 'hg evolve' to update to its successor: b4deda8116ef) 582 (use 'hg evolve' to update to its successor: 6aa6f90a9f68)
583 $ echo 'gotta break' >> a 583 $ echo 'gotta break' >> a
584 $ hg amend 584 $ hg amend
585 2 new content-divergent changesets 585 2 new content-divergent changesets
586 586
587 # reamend so that the case is not the first precursor. 587 # reamend so that the case is not the first precursor.
592 6: draft 592 6: draft
593 593
594 $ glog 594 $ glog
595 @ 6:13c1b75640a1@default(draft) bk:[] More addition (2) 595 @ 6:13c1b75640a1@default(draft) bk:[] More addition (2)
596 | 596 |
597 | * 4:b4deda8116ef@default(draft) bk:[] More addition 597 | * 4:6aa6f90a9f68@default(draft) bk:[] More addition
598 |/ 598 |/
599 o 0:6569b5a81c7e@default(public) bk:[] root 599 o 0:6569b5a81c7e@default(public) bk:[] root
600 600
601 601
602 $ hg evolve -qn --content-divergent --no-all 602 $ hg evolve -qn --content-divergent --no-all
603 hg update -c 13c1b75640a1 && 603 hg update -c 13c1b75640a1 &&
604 hg merge b4deda8116ef && 604 hg merge 6aa6f90a9f68 &&
605 hg commit -m "auto merge resolving conflict between 13c1b75640a1 and b4deda8116ef"&& 605 hg commit -m "auto merge resolving conflict between 13c1b75640a1 and 6aa6f90a9f68"&&
606 hg up -C 867e43582046 && 606 hg up -C 867e43582046 &&
607 hg revert --all --rev tip && 607 hg revert --all --rev tip &&
608 hg commit -m "`hg log -r 13c1b75640a1 --template={desc}`"; 608 hg commit -m "`hg log -r 13c1b75640a1 --template={desc}`";
609 $ hg evolve --content-divergent --no-all 609 $ hg evolve --content-divergent --no-all
610 merge:[6] More addition (2) 610 merge:[6] More addition (2)
631 631
632 $ hg resolve -m 632 $ hg resolve -m
633 (no more unresolved files) 633 (no more unresolved files)
634 continue: hg evolve --continue 634 continue: hg evolve --continue
635 $ hg evolve --continue 635 $ hg evolve --continue
636 working directory is now at 4a175c20d152 636 working directory is now at 22dc0f618f0d
637 $ glog 637 $ glog
638 @ 7:4a175c20d152@default(draft) bk:[] More addition (2) 638 @ 7:22dc0f618f0d@default(draft) bk:[] More addition (2)
639 | 639 |
640 o 0:6569b5a81c7e@default(public) bk:[] root 640 o 0:6569b5a81c7e@default(public) bk:[] root
641 641
642 $ hg exp --config diff.unified=3 642 $ hg exp --config diff.unified=3
643 # HG changeset patch 643 # HG changeset patch
644 # User test 644 # User test
645 # Date 0 0 645 # Date 0 0
646 # Thu Jan 01 00:00:00 1970 +0000 646 # Thu Jan 01 00:00:00 1970 +0000
647 # Node ID 4a175c20d152f8f4266a3b85a5dcf74b5a032719 647 # Node ID 22dc0f618f0d8714c611e7a683ad229a575f167c
648 # Parent 6569b5a81c7e307ddc076550e8c0f6d75b6effcd 648 # Parent 6569b5a81c7e307ddc076550e8c0f6d75b6effcd
649 More addition (2) 649 More addition (2)
650 650
651 diff --git a/a b/a 651 diff --git a/a b/a
652 --- a/a 652 --- a/a
962 with: [3] E3 962 with: [3] E3
963 base: [1] E1 963 base: [1] E1
964 merging numbers 964 merging numbers
965 merging romans 965 merging romans
966 1 files updated, 2 files merged, 0 files removed, 0 files unresolved 966 1 files updated, 2 files merged, 0 files removed, 0 files unresolved
967 working directory is now at ce0aaa423a89 967 working directory is now at e7cb08a7241a
968 $ hg status 968 $ hg status
969 $ hg amend -m 'E4' 969 $ hg amend -m 'E4'
970 $ hg export 970 $ hg export
971 # HG changeset patch 971 # HG changeset patch
972 # User test 972 # User test
973 # Date 0 0 973 # Date 0 0
974 # Thu Jan 01 00:00:00 1970 +0000 974 # Thu Jan 01 00:00:00 1970 +0000
975 # Node ID b8e4a5a633b6fb38bbc9011601b3342573733083 975 # Node ID 50bb00cad3206c79d231a621e319772302a88d8d
976 # Parent 6d1fdf6de7e2d9fc9b098aa286b60785bbeaab7a 976 # Parent 6d1fdf6de7e2d9fc9b098aa286b60785bbeaab7a
977 E4 977 E4
978 978
979 diff --git a/numbers b/numbers 979 diff --git a/numbers b/numbers
980 --- a/numbers 980 --- a/numbers
993 +ii 993 +ii
994 @@ -6,1 +6,1 @@ 994 @@ -6,1 +6,1 @@
995 -VI 995 -VI
996 +vi 996 +vi
997 $ hg log -G 997 $ hg log -G
998 @ 5:b8e4a5a633b6@default(draft) E4 [] 998 @ 5:50bb00cad320@default(draft) E4 []
999 | 999 |
1000 o 0:6d1fdf6de7e2@default(draft) root [] 1000 o 0:6d1fdf6de7e2@default(draft) root []
1001 1001
1002 $ hg debugobsolete 1002 $ hg debugobsolete
1003 4a250e5bd992a897655e3b6f238e12452cf063e9 084ae625fa51ca8c441ba1d2bf0f974b21671017 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '9', 'operation': 'amend', 'user': 'test'} 1003 4a250e5bd992a897655e3b6f238e12452cf063e9 084ae625fa51ca8c441ba1d2bf0f974b21671017 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '9', 'operation': 'amend', 'user': 'test'}
1004 4a250e5bd992a897655e3b6f238e12452cf063e9 19ed1bf64a2cc2a824df5ac33a436eca1ae0475d 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '9', 'operation': 'amend', 'user': 'test'} 1004 4a250e5bd992a897655e3b6f238e12452cf063e9 19ed1bf64a2cc2a824df5ac33a436eca1ae0475d 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '9', 'operation': 'amend', 'user': 'test'}
1005 084ae625fa51ca8c441ba1d2bf0f974b21671017 ce0aaa423a89436c9a9b320283dc0cc89f04a91d 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '9', 'operation': 'evolve', 'user': 'test'} 1005 084ae625fa51ca8c441ba1d2bf0f974b21671017 e7cb08a7241a98c908db298b61fc033b27f648c7 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '9', 'operation': 'evolve', 'user': 'test'}
1006 19ed1bf64a2cc2a824df5ac33a436eca1ae0475d ce0aaa423a89436c9a9b320283dc0cc89f04a91d 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '9', 'operation': 'evolve', 'user': 'test'} 1006 19ed1bf64a2cc2a824df5ac33a436eca1ae0475d e7cb08a7241a98c908db298b61fc033b27f648c7 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '9', 'operation': 'evolve', 'user': 'test'}
1007 ce0aaa423a89436c9a9b320283dc0cc89f04a91d b8e4a5a633b6fb38bbc9011601b3342573733083 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'test'} 1007 e7cb08a7241a98c908db298b61fc033b27f648c7 50bb00cad3206c79d231a621e319772302a88d8d 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'test'}
1008 $ hg obslog --patch 1008 $ hg obslog --patch
1009 @ b8e4a5a633b6 (5) E4 1009 @ 50bb00cad320 (5) E4
1010 | 1010 |
1011 x ce0aaa423a89 (4) <<<<<<< divergent 1011 x e7cb08a7241a (4) <<<<<<< divergent
1012 |\ reworded(description) as b8e4a5a633b6 using amend by test (Thu Jan 01 00:00:00 1970 +0000) 1012 |\ reworded(description) as 50bb00cad320 using amend by test (Thu Jan 01 00:00:00 1970 +0000)
1013 | | diff -r ce0aaa423a89 -r b8e4a5a633b6 changeset-description 1013 | | diff -r e7cb08a7241a -r 50bb00cad320 changeset-description
1014 | | --- a/changeset-description 1014 | | --- a/changeset-description
1015 | | +++ b/changeset-description 1015 | | +++ b/changeset-description
1016 | | @@ -1,4 +1,1 @@ 1016 | | @@ -1,4 +1,1 @@
1017 | | -<<<<<<< divergent 1017 | | -<<<<<<< divergent
1018 | | -E2||||||| base 1018 | | -E2||||||| base
1020 | | -E3>>>>>>> other 1020 | | -E3>>>>>>> other
1021 | | +E4 1021 | | +E4
1022 | | 1022 | |
1023 | | 1023 | |
1024 x | 084ae625fa51 (2) E2 1024 x | 084ae625fa51 (2) E2
1025 | | rewritten(description, content) as ce0aaa423a89 using evolve by test (Thu Jan 01 00:00:00 1970 +0000) 1025 | | rewritten(description, content) as e7cb08a7241a using evolve by test (Thu Jan 01 00:00:00 1970 +0000)
1026 | | diff -r 084ae625fa51 -r ce0aaa423a89 changeset-description 1026 | | diff -r 084ae625fa51 -r e7cb08a7241a changeset-description
1027 | | --- a/changeset-description 1027 | | --- a/changeset-description
1028 | | +++ b/changeset-description 1028 | | +++ b/changeset-description
1029 | | @@ -1,1 +1,4 @@ 1029 | | @@ -1,1 +1,4 @@
1030 | | -E2 1030 | | -E2
1031 | | +<<<<<<< divergent 1031 | | +<<<<<<< divergent
1052 | | -II 1052 | | -II
1053 | | +ii 1053 | | +ii
1054 | | 1054 | |
1055 | | 1055 | |
1056 | x 19ed1bf64a2c (3) E3 1056 | x 19ed1bf64a2c (3) E3
1057 |/ rewritten(description, content) as ce0aaa423a89 using evolve by test (Thu Jan 01 00:00:00 1970 +0000) 1057 |/ rewritten(description, content) as e7cb08a7241a using evolve by test (Thu Jan 01 00:00:00 1970 +0000)
1058 | diff -r 19ed1bf64a2c -r ce0aaa423a89 changeset-description 1058 | diff -r 19ed1bf64a2c -r e7cb08a7241a changeset-description
1059 | --- a/changeset-description 1059 | --- a/changeset-description
1060 | +++ b/changeset-description 1060 | +++ b/changeset-description
1061 | @@ -1,1 +1,4 @@ 1061 | @@ -1,1 +1,4 @@
1062 | -E3 1062 | -E3
1063 | +<<<<<<< divergent 1063 | +<<<<<<< divergent