tests/test-rebuildstate.t
author Pierre-Yves David <pierre-yves.david@fb.com>
Thu, 28 May 2015 23:49:19 -0700
changeset 25339 c50655b9c856
parent 23840 ddc17eaf0f1b
child 27174 9fbe3545e4bd
permissions -rw-r--r--
listkey: display the size of the listkey payload in a debug message This is a useful information to have in general and we already have debug output related to listkeys. I'm planning to play around with massive amount of phases roots and bookmarks so having this data in debug will be very useful. This already got me to spot that one of the Logilab's review repo is exchanging 65KB of phases data during each exchanges.

basic test for hg debugrebuildstate

  $ hg init repo
  $ cd repo

  $ touch foo bar
  $ hg ci -Am 'add foo bar'
  adding bar
  adding foo

  $ touch baz
  $ hg add baz
  $ hg rm bar

  $ hg debugrebuildstate

state dump after

  $ hg debugstate --nodates | sort
  n 644         -1 set                 bar
  n 644         -1 set                 foo

status

  $ hg st -A
  ! bar
  ? baz
  C foo

  $ cd ..