Mercurial > public > mercurial-scm > hg-stable
diff tests/test-rollback.t @ 41384:57c462db87fd
localrepo: use context manager for transaction in commit()
A side-effect is that the transaction is released a little earlier, so
the "commit message saved in ..." messages now comes after the
"rollback completed" message. That seems slightly better to me.
Differential Revision: https://phab.mercurial-scm.org/D5622
author | Martin von Zweigbergk <martinvonz@google.com> |
---|---|
date | Wed, 16 Jan 2019 17:33:47 -0800 |
parents | c2aea007130b |
children | 7a4e1d245f19 |
line wrap: on
line diff
--- a/tests/test-rollback.t Wed Jan 16 17:46:39 2019 -0800 +++ b/tests/test-rollback.t Wed Jan 16 17:33:47 2019 -0800 @@ -113,9 +113,9 @@ > echo "another precious commit message" > "$1" > __EOF__ $ HGEDITOR="\"sh\" \"`pwd`/editor.sh\"" hg --config hooks.pretxncommit=false commit 2>&1 - note: commit message saved in .hg/last-message.txt transaction abort! rollback completed + note: commit message saved in .hg/last-message.txt abort: pretxncommit hook exited with status * (glob) [255] $ cat .hg/last-message.txt