comparison tests/test-push-race.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 89630d0b3e23
comparison
equal deleted inserted replaced
35708:03e921942163 35709:1a09dad8b85a
1705 adding manifests 1705 adding manifests
1706 adding file changes 1706 adding file changes
1707 added 1 changesets with 1 changes to 1 files (+1 heads) 1707 added 1 changesets with 1 changes to 1 files (+1 heads)
1708 1 new obsolescence markers 1708 1 new obsolescence markers
1709 obsoleted 1 changesets 1709 obsoleted 1 changesets
1710 1 new orphan changesets
1710 new changesets 720c5163ecf6 1711 new changesets 720c5163ecf6
1711 (run 'hg heads .' to see heads, 'hg merge' to merge) 1712 (run 'hg heads .' to see heads, 'hg merge' to merge)
1712 $ hg -R ./client-other pull 1713 $ hg -R ./client-other pull
1713 pulling from ssh://user@dummy/server 1714 pulling from ssh://user@dummy/server
1714 searching for changes 1715 searching for changes
1716 adding manifests 1717 adding manifests
1717 adding file changes 1718 adding file changes
1718 added 1 changesets with 1 changes to 1 files (+1 heads) 1719 added 1 changesets with 1 changes to 1 files (+1 heads)
1719 1 new obsolescence markers 1720 1 new obsolescence markers
1720 obsoleted 1 changesets 1721 obsoleted 1 changesets
1722 1 new orphan changesets
1721 new changesets 720c5163ecf6 1723 new changesets 720c5163ecf6
1722 (run 'hg heads .' to see heads, 'hg merge' to merge) 1724 (run 'hg heads .' to see heads, 'hg merge' to merge)
1723 $ hg -R ./client-racy pull 1725 $ hg -R ./client-racy pull
1724 pulling from ssh://user@dummy/server 1726 pulling from ssh://user@dummy/server
1725 searching for changes 1727 searching for changes
1726 adding changesets 1728 adding changesets
1727 adding manifests 1729 adding manifests
1728 adding file changes 1730 adding file changes
1729 added 1 changesets with 0 changes to 0 files 1731 added 1 changesets with 0 changes to 0 files
1732 1 new orphan changesets
1730 new changesets a98a47d8b85b 1733 new changesets a98a47d8b85b
1731 (run 'hg update' to get a working copy) 1734 (run 'hg update' to get a working copy)
1732 1735
1733 $ hg -R server debugobsolete 1736 $ hg -R server debugobsolete
1734 b0ee3d6f51bc4c0ca6d4f2907708027a6c376233 720c5163ecf64dcc6216bee2d62bf3edb1882499 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} 1737 b0ee3d6f51bc4c0ca6d4f2907708027a6c376233 720c5163ecf64dcc6216bee2d62bf3edb1882499 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1790 1 files updated, 0 files merged, 0 files removed, 0 files unresolved 1793 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1791 $ echo bbb >> client-other/a 1794 $ echo bbb >> client-other/a
1792 $ hg -R client-other/ branch --force default 1795 $ hg -R client-other/ branch --force default
1793 marked working directory as branch default 1796 marked working directory as branch default
1794 $ hg -R client-other/ commit -m "C-W" 1797 $ hg -R client-other/ commit -m "C-W"
1798 1 new orphan changesets
1795 created new head 1799 created new head
1796 $ ID_V=`hg -R client-other log -T '{node}\n' -r 'desc("C-V")'` 1800 $ ID_V=`hg -R client-other log -T '{node}\n' -r 'desc("C-V")'`
1797 $ ID_W=`hg -R client-other log -T '{node}\n' -r 'desc("C-W")'` 1801 $ ID_W=`hg -R client-other log -T '{node}\n' -r 'desc("C-W")'`
1798 $ hg -R client-other debugobsolete $ID_V $ID_W 1802 $ hg -R client-other debugobsolete $ID_V $ID_W
1799 obsoleted 1 changesets 1803 obsoleted 1 changesets
1816 remote: adding manifests 1820 remote: adding manifests
1817 remote: adding file changes 1821 remote: adding file changes
1818 remote: added 1 changesets with 0 changes to 1 files (+1 heads) 1822 remote: added 1 changesets with 0 changes to 1 files (+1 heads)
1819 remote: 1 new obsolescence markers 1823 remote: 1 new obsolescence markers
1820 remote: obsoleted 1 changesets 1824 remote: obsoleted 1 changesets
1825 remote: 1 new orphan changesets
1821 1826
1822 $ release $TESTTMP/watchfile 1827 $ release $TESTTMP/watchfile
1823 1828
1824 Check the result of the push 1829 Check the result of the push
1825 1830