comparison tests/test-split.t @ 35709:1a09dad8b85a

evolution: report new unstable changesets This adds a transaction summary callback that reports the number of new orphan, content-divergent and phase-divergent changesets. The code for reporting it is based on the code from the evolve extension, but simplified a bit. It simply counts the numbers for each kind of instability before and after the transaction. That's obviously not very efficient, but it's easy to reason about, so I'm doing this as a first step that can make us quite confident about the test case changes. We can optimize it later and make sure that the tests are not affected. The code has been used in the evolve extension for a long time and has apparently been sufficiently fast, so it doesn't seem like a pressing issue. Unlike the evolve extension's version of this report, this version applies to all commands (or all transactions run as part of any command, to be exact). Differential Revision: https://phab.mercurial-scm.org/D1867
author Martin von Zweigbergk <martinvonz@google.com>
date Sun, 14 Jan 2018 23:59:17 -0800
parents 9b3f95d9783d
children 7bc33d677c0c
comparison
equal deleted inserted replaced
35708:03e921942163 35709:1a09dad8b85a
415 $ runsplit -r 1 --no-rebase 415 $ runsplit -r 1 --no-rebase
416 abort: cannot split changeset with children without rebase 416 abort: cannot split changeset with children without rebase
417 [255] 417 [255]
418 #else 418 #else
419 $ runsplit -r 1 --no-rebase >/dev/null 419 $ runsplit -r 1 --no-rebase >/dev/null
420 3 new orphan changesets
420 $ hg bookmark 421 $ hg bookmark
421 d1 2:b5c5ea414030 422 d1 2:b5c5ea414030
422 * d2 3:f4a0a8d004cc 423 * d2 3:f4a0a8d004cc
423 d3 4:777940761eba 424 d3 4:777940761eba
424 r1 0:a61bcde8c529 425 r1 0:a61bcde8c529
457 > \|/ 458 > \|/
458 > B 459 > B
459 > | 460 > |
460 > A 461 > A
461 > EOS 462 > EOS
463 2 new orphan changesets
462 $ eval `hg tags -T '{tag}={node}\n'` 464 $ eval `hg tags -T '{tag}={node}\n'`
463 $ rm .hg/localtags 465 $ rm .hg/localtags
464 $ hg split $B --config experimental.evolution=createmarkers 466 $ hg split $B --config experimental.evolution=createmarkers
465 abort: split would leave orphaned changesets behind 467 abort: split would leave orphaned changesets behind
466 [255] 468 [255]