Mercurial > hg
diff tests/test-obsolete-distributed.t @ 44545:bd7b2c8d06cc
pull: add `--confirm` flag to confirm before writing changes
This introduces a new flag to pull command `--confirm` and also a config option
named `pull.confirm` which if used will prompt user describing changes which are
pulled and asking whether to accept them or not.
Differential Revision: https://phab.mercurial-scm.org/D8200
author | Pulkit Goyal <7895pulkit@gmail.com> |
---|---|
date | Sat, 29 Feb 2020 12:58:38 +0530 |
parents | 34a46d48d24e |
children | ed84a4d48910 |
line wrap: on
line diff
--- a/tests/test-obsolete-distributed.t Sat Feb 29 12:58:13 2020 +0530 +++ b/tests/test-obsolete-distributed.t Sat Feb 29 12:58:38 2020 +0530 @@ -138,12 +138,37 @@ $ hg up 'desc("ROOT")' 0 files updated, 0 files merged, 1 files removed, 0 files unresolved - $ hg pull + $ hg pull --confirm --config ui.interactive=True << EOF + > n + > EOF pulling from $TESTTMP/distributed-chain-building/server searching for changes adding changesets adding manifests adding file changes + adding 1 changesets with 1 changes to 1 files (+1 heads) + 1 new obsolescence markers + obsoleting 1 changesets + new changesets 391a2bf12b1b (1 drafts) + accept incoming changes (yn)? n + transaction abort! + rollback completed + abort: user aborted + [255] + + $ hg pull --confirm --config ui.interactive=True << EOF + > y + > EOF + pulling from $TESTTMP/distributed-chain-building/server + searching for changes + adding changesets + adding manifests + adding file changes + adding 1 changesets with 1 changes to 1 files (+1 heads) + 1 new obsolescence markers + obsoleting 1 changesets + new changesets 391a2bf12b1b (1 drafts) + accept incoming changes (yn)? y added 1 changesets with 1 changes to 1 files (+1 heads) 1 new obsolescence markers obsoleted 1 changesets