Mercurial > hg
changeset 50067:059910ac7b76
rollback: display some graphlog before/after a test piece
This make the situation clearer.
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Wed, 15 Feb 2023 20:48:51 +0100 |
parents | ebb8648483db |
children | b35fb0e5b8d6 |
files | tests/test-rollback.t |
diffstat | 1 files changed, 24 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/tests/test-rollback.t Wed Feb 15 20:47:08 2023 +0100 +++ b/tests/test-rollback.t Wed Feb 15 20:48:51 2023 +0100 @@ -65,17 +65,32 @@ $ hg commit -m'modify a again' $ echo b > b $ hg bookmark bar -r default #making bar active, before the transaction + $ hg log -G --template '{rev} [{branch}] ({bookmarks}) {desc|firstline}\n' + @ 1 [test] (foo) modify a again + | + o 0 [default] (bar) add a again + $ hg commit -Am'add b' adding b - $ hg log --template '{rev} {branch} {desc|firstline}\n' - 2 test add b - 1 test modify a again - 0 default add a again + $ hg log -G --template '{rev} [{branch}] ({bookmarks}) {desc|firstline}\n' + @ 2 [test] (foo) add b + | + o 1 [test] () modify a again + | + o 0 [default] (bar) add a again + $ hg update bar 1 files updated, 0 files merged, 1 files removed, 0 files unresolved (activating bookmark bar) $ cat .hg/undo.branch ; echo test + $ hg log -G --template '{rev} [{branch}] ({bookmarks}) {desc|firstline}\n' + o 2 [test] (foo) add b + | + o 1 [test] () modify a again + | + @ 0 [default] (bar) add a again + $ hg rollback abort: rollback of last commit while not checked out may lose data (use -f to force) @@ -84,6 +99,11 @@ repository tip rolled back to revision 1 (undo commit) $ hg id -n 0 + $ hg log -G --template '{rev} [{branch}] ({bookmarks}) {desc|firstline}\n' + o 1 [test] (foo) modify a again + | + @ 0 [default] (bar) add a again + $ hg branch default $ cat .hg/bookmarks.current ; echo