Mercurial > hg
diff tests/test-share.t @ 48466:bf2738e03e96
share: make it possible to control the working copy format variant
A share will use the same format as its source for the store, but there are no
reason to not lets it control the working copy variant at creation time.
So we make it so.
Differential Revision: https://phab.mercurial-scm.org/D11892
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Tue, 07 Dec 2021 15:14:08 +0100 |
parents | 5e6542143d40 |
children | 68b7faeb6ef3 |
line wrap: on
line diff
--- a/tests/test-share.t Tue Dec 07 14:51:45 2021 +0100 +++ b/tests/test-share.t Tue Dec 07 15:14:08 2021 +0100 @@ -284,3 +284,25 @@ $ hg share nostore sharednostore abort: cannot create shared repository as source was created with 'format.usestore' config disabled [255] + +Check that (safe) share can control wc-specific format variant at creation time +------------------------------------------------------------------------------- + +#if no-rust + + $ cat << EOF >> $HGRCPATH + > [storage] + > dirstate-v2.slow-path = allow + > EOF + +#endif + + $ hg init repo-safe-d1 --config format.use-share-safe=yes --config format.exp-rc-dirstate-v2=no + $ hg debugformat -R repo-safe-d1 | grep dirstate-v2 + dirstate-v2: no + + $ hg share repo-safe-d1 share-safe-d2 --config format.use-share-safe=yes --config format.exp-rc-dirstate-v2=yes + updating working directory + 0 files updated, 0 files merged, 0 files removed, 0 files unresolved + $ hg debugformat -R share-safe-d2 | grep dirstate-v2 + dirstate-v2: yes