sapling/tests/test-commit-amend-reuse-rawfctx.t
Jun Wu 66f2e5f45e branch: disable branchcache and drop all branches other than "default"
Summary:
This hardcodes several perftweaks configs that have been enabled for major FB
repos for months:

  [perftweaks]
  disablebranchcache = True
  disablebranchcache2 = True
  disableresolvingbranches = True
  disableupdatebranchcacheoncommit = True

Practically, this means the branchmap is now just `{'default': heads}`. (i.e.
there are no named branches other than `default`), and branchcache is removed
(i.e. `.hg/cache` does not exist without clindex or in-repo tags).

This diff only makes easy-to-verify logic changes by assuming the configs and
removing dead code. Things can be further cleaned up. They will be done by
upcoming changes.

Most test changes are due to the fact that `.hg/cache` is no longer created.

Reviewed By: singhsrb

Differential Revision: D14179858

fbshipit-source-id: 479f7427168eb1d9614a973e273a229e50f5620a
2019-02-22 21:02:41 -08:00

37 lines
832 B
Perl

$ enable obsstore
File node could be reused during commit --amend
$ newrepo
$ echo 1 > a
$ echo 2 > b
$ hg commit -m 12 -A a b
$ echo 3 >> a
$ hg commit -m 3
$ hg commit --debug --amend -m 'without content change'
amending changeset 0bd823dca296
copying changeset 0bd823dca296 to dd3d87f356df
committing files:
a
reusing a filelog node (exact match)
committing manifest
committing changelog
committed changeset 2:92bc7a9d76f010337ece134e095054c094d44760
#if execbit
File node is reused for mode-only change
$ chmod +x b
$ hg ci --debug --amend -m 'without content change'
amending changeset 92bc7a9d76f0
committing files:
a
reusing a filelog node (exact match)
b
committing manifest
committing changelog
committed changeset 3:ba954a28eb454eb63e7348349f8e87e7b1be3601
#endif