Commit Graph

1611 Commits

Author SHA1 Message Date
Phil Cohen
8950244fd8 test-check-confog-hg: remove hiteditng override
D942 removed histeditng, so this should go as well.
2017-10-10 19:56:51 -07:00
Zhihui Huang
a6d5ff8f57 p4fastimport: fix sync commit - complete workflow
Differential Revision: https://phabricator.intern.facebook.com/D5966213
2017-10-10 10:14:00 -07:00
Durham Goode
cb67413bf8 sqldirstate: remove test
sqldirstate is now gone, so let's remove this test dependency.
2017-10-05 13:06:56 -07:00
Durham Goode
19168fe362 tests: update remotefilelog test with phase head capability
Upstream added a new capability, so the tests need updating to show it.
2017-10-04 18:47:11 -07:00
Phil Cohen
29af53de91 test-check-config-hg.t: remove spurious entries 2017-10-04 18:21:28 -07:00
Durham Goode
20612dfe95 tests: update to match upstream changes
Upstream added a new capability about phase heads, so we need to update wire
protocol output.
2017-10-04 18:16:44 -07:00
Durham Goode
eb70db8aaa treemanifest: update the test due to upstream change
10e162bb9bf in upstream hg changed how phases are sent, which changed this
output. It's a benign update.
2017-10-04 18:11:24 -07:00
Phil Cohen
edd23c893d test-check-config-hg.t: revert some changes that shouldn't have been included 2017-10-04 18:02:38 -07:00
Phil Cohen
fe9bb9c641 test-check-config-hg.t: new values post-sqldirstate 2017-10-04 17:58:03 -07:00
Phil Cohen
ad9a59cbe3 progressfile: update test to account for D820
D820 makes the estimation more accurate, so new values are expected.
2017-10-04 17:56:36 -07:00
Phil Cohen
82f05b3c75 sqldirstate: remove
We no longer use this experiment and the upstream refactor breaks it. Let's remove it.

Test Plan:
all sqldirstate tests pass now

Differential Revision: https://phab.mercurial-scm.org/D944
2017-10-04 17:53:40 -07:00
David Soria Parra
a52fe379df p4fastimport: fix resetting file flags
When a file changed to include a flag and then the flag is removed we did not
correctly remove the flag. We now correctly set flags for all revisions.

Differential Revision: https://phab.mercurial-scm.org/D920
2017-10-04 12:57:27 -07:00
Stanislau Hlebik
2502bb5d2c infinitepush: revert D721
Summary:
This diff caused a regression - clients may not have a tree manifests entries
for old commits. That causes infinitepush fail with

```
 KeyError: ('', 'f6db63080ed0d9a81adf2cb266646cf5cf73bb79')
```

Test Plan: Run infinitepush with this diff reverted, make sure it doesn't fail

Reviewers: #fbhgext, ryanmce, durham

Reviewed By: #fbhgext, ryanmce

Differential Revision: https://phab.mercurial-scm.org/D921
2017-10-03 05:49:06 -07:00
Ryan McElroy
56bc2afcf0 tweakdefaults: add abort flag for colon revset
Reviewers: #fbhgext, quark

Reviewed By: #fbhgext, quark

Subscribers: quark

Differential Revision: https://phab.mercurial-scm.org/D904
2017-10-03 02:09:23 -07:00
Ryan McElroy
49a8dc8d10 tweakdefaults: minimize revsets test
Reviewers: #fbhgext, quark

Reviewed By: #fbhgext, quark

Differential Revision: https://phab.mercurial-scm.org/D903
2017-10-03 02:09:23 -07:00
Ryan McElroy
fd9b2e03b1 tweakdefaults: split out revset tests
Reviewers: #fbhgext, quark

Reviewed By: #fbhgext, quark

Differential Revision: https://phab.mercurial-scm.org/D902
2017-10-03 02:09:23 -07:00
Ryan McElroy
49bac3147b tweakdefaults: quote update string in test to pass check-code
Test Plan: tests

Reviewers: #fbhgext, mbthomas

Reviewed By: #fbhgext, mbthomas

Differential Revision: https://phab.mercurial-scm.org/D881
2017-10-01 07:13:09 -07:00
Stanislau Hlebik
233ae9f9b1 remotefilelog: add more logging for prefetching heuristics
Summary: The goal of the whole series is to have logging around linknode fixup. It's a slow operation, and we have two heuristics to make it faster. Unfortunately we have no idea about how well these heuristics actually help. This series of diffs aims to fix this problem. After this series is landed and logging is enabled, I hope that we can find out if we really these heuristics at all.

Test Plan: Run test-remotefilelog-linknodes.t

Reviewers: #fbhgext, quark

Reviewed By: #fbhgext, quark

Differential Revision: https://phab.mercurial-scm.org/D841
2017-10-01 05:45:27 -07:00
Stanislau Hlebik
0fb7860557 remotefilelog: time fastlog requests
Summary: The goal of the whole series is to have logging around linknode fixup. It's a slow operation, and we have two heuristics to make it faster. Unfortunately we have no idea about how well these heuristics actually help. This series of diffs aims to fix this problem. After this series is landed and logging is enabled, I hope that we can find out if we really these heuristics at all.

Test Plan: Run test-remotefilelog-linknodes.t

Reviewers: #fbhgext, quark

Reviewed By: #fbhgext, quark

Differential Revision: https://phab.mercurial-scm.org/D839
2017-10-01 05:45:27 -07:00
Stanislau Hlebik
f39bc3ba1e remotefilelog: add linknode fixup logging
Summary:
The goal of the whole series is to have logging around linknode fixup. It's a slow operation, and we have two heuristics to make it faster. Unfortunately we have no idea about how well these heuristics actually help. This series of diffs aims to fix this problem. After this series is landed and logging is enabled, I hope that we can find out if we really these heuristics at all.

Let's log more data to make it easier to analyze where and how often does
linknode adjusing happen.

Test Plan: Run test-remotefilelog-linknodes.t

Reviewers: #fbhgext, quark

Reviewed By: #fbhgext, quark

Subscribers: quark

Differential Revision: https://phab.mercurial-scm.org/D838
2017-10-01 05:45:27 -07:00
Jun Wu
07643e2d99 undo: update test to reflect upstream changes
This is a simple `rt -i` fix for changes caused by upstream 83b647ce1cec and
976f5a9c1fd2. We probably want to change our template implementation to
de-dup hashes in the future.
2017-10-01 05:45:27 -07:00
Shravya Reddy Kuchikulla
3c9328d1ee sparse: add a --cwd-list option
This diff adds an option --cwd-list to hg sparse. This will return the
contents of the current directory.  The files that are in the sparse profile are
annotated with a '-' indicator.

Test Plan:
Tested by running the command 'hg sparse --cwd-list' in various folders.

Differential Revision: https://phab.mercurial-scm.org/D731
2017-10-01 05:45:27 -07:00
Diego Caballero
60ea7b5141 hg update hint
Differential Revision: https://phab.mercurial-scm.org/D834
2017-09-28 11:30:37 -07:00
Ryan McElroy
1ac1a987b3 fbamend: fix typo and shorten advice
Summary: Shorter and sweeter and hopefully more correct.

Reviewers: #fbhgext, mjpieters

Reviewed By: mjpieters

Subscribers: mjpieters

Differential Revision: https://phab.mercurial-scm.org/D827
2017-09-27 06:43:51 -07:00
Ryan McElroy
65cf7910fc tests: not rebasing now prints out names
Reviewers: #fbhgext, mjpieters

Reviewed By: mjpieters

Differential Revision: https://phab.mercurial-scm.org/D825
2017-09-27 06:43:51 -07:00
Ryan McElroy
5ab0d8e6cf tests: tip moved to after other names
Summary: Namespace order in rebase was changed in https://phab.mercurial-scm.org/D741

Reviewers: #fbhgext, mjpieters

Reviewed By: mjpieters

Differential Revision: https://phab.mercurial-scm.org/D824
2017-09-27 06:43:51 -07:00
Ryan McElroy
59d15d70c8 scm-prompt: fix single quotes showing up with no format string
Summary: Regression that wasn't tested by the tests before

Test Plan: This is now tested with a new test

Reviewers: #fbhgext, mjpieters

Reviewed By: mjpieters

Differential Revision: https://phab.mercurial-scm.org/D823
2017-09-27 06:43:51 -07:00
Ryan McElroy
3add344955 scm-prompt: update test for changed hg output
Reviewers: #fbhgext, stash

Reviewed By: #fbhgext, stash

Differential Revision: https://phab.mercurial-scm.org/D822
2017-09-27 06:43:51 -07:00
Ryan McElroy
b20938c285 tweakdefaults: explicitly enable/disable single colon warning
Summary:
I think this is a better way of surfacing this warning. It also allows
us to tweak the message so we can point at new documentation I have already
written up.

Test Plan: Updated test

Reviewers: #fbhgext, mbthomas, durham, singhsrb

Reviewed By: #fbhgext, mbthomas, durham, singhsrb

Subscribers: singhsrb, quark

Differential Revision: https://phab.mercurial-scm.org/D812
2017-09-27 14:05:56 +01:00
Martijn Pieters
6f5e6b7d91 More test output fixing for debugobsolete 2017-09-27 03:59:30 -07:00
Saurabh Singh
4107b6303c tweakdefaults: fix test to avoid unnecessary double execution
D802 added two test cases in the test but the test cases are only used
for a very little portion of the test and therefore, result in needless double
execution for most of the test. Therefore, this commit removes the test cases
and instead, handles the different cases by passing the corresponding config
option.

Test Plan:
ran test-tweakdefaults.t

Differential Revision: https://phab.mercurial-scm.org/D814
2017-09-26 14:01:58 -07:00
Martijn Pieters
1f6351d8a1 Update obstore tests 2017-09-26 09:11:19 -07:00
Mark Thomas
a44fc44f24 sparse: add --sparse option to hg diff
Add a --sparse option to `hg diff` which filters the diff to include only files
that are part of the sparse profile.

When files are moved or copied across the sparse profile boundary, they will
show as added or removed (for moves) in the diff.  This is the same behaviour
as `hg diff --root`.

Test Plan:
Expand `tests/test-sparse-diff.t`

Differential Revision: https://phab.mercurial-scm.org/D797
2017-09-26 03:24:56 -07:00
Mark Thomas
b0c997501c sparse: get data for excluded files from working copy parent
When commands like 'diff' request the contents of files from a workingfilectx,
normally this is satisfied by reading from disk.  For files outside the sparse
checkout this doesn't work, so instead we must return the content from the
working copy parent.

Test Plan:
`tests/test-sparse-diff.t`

Differential Revision: https://phab.mercurial-scm.org/D788
2017-09-26 03:24:56 -07:00
Saurabh Singh
92177b3187 tweakdefaults: add config to enable/disable developer warnings
Summary:
Adding a config to control (only enable/disable for now) developer
warnings. This allows disabling the warnings on platforms like servers.

Test Plan: Updated and ran test-tweakdefaults.t

Reviewers: #fbhgext, durham

Reviewed By: #fbhgext, durham

Differential Revision: https://phab.mercurial-scm.org/D802
2017-09-23 16:58:58 -07:00
Shivram Khandeparker
7fcb01426a remotefilelog: using fastlog as a fast path to fix linkrev
Summary:
The _adjustlinknode function in remotefilectx currently has a slow case where
it must prefetch history from the server to lookup the correct linkcode.
This change makes use of fastlog (if enabled for the repo) to speed up the
linknode lookup as fastlog will already have the correct linkrev. If fastlog
is not enabled or the fastlog call fails for some reason then it will fall
back to the old method.

Test Plan: Added new test cases in test-remotefilelog-linknodes.t

Reviewers: ikostia, stash, #fbhgext

Differential Revision: https://phab.mercurial-scm.org/D620
2017-09-22 10:08:58 -07:00
Durham Goode
286d6bbe18 infinitepush: send treepack parts with the client push
This makes the client side pushes also include tree packs in the push.

Also adds a test to see that the tree parts round trip between two tree-only
clients.

Differential Revision: https://phab.mercurial-scm.org/D721
2017-09-22 08:55:56 -07:00
Ryan McElroy
54b4eb4a85 scm-prompt: show elipsis only if there are additional remote bookmarks
Test Plan: `rt`

Reviewers: #fbhgext, stash

Reviewed By: #fbhgext, stash

Subscribers: stash

Differential Revision: https://phab.mercurial-scm.org/D794
2017-09-22 08:31:06 -07:00
Ryan McElroy
68ea4e433c scm-prompt: add locked state
Summary:
If you're working n multiple terminals on the same repository, it is
often useful to know if a command you're about to run might block due to an
already-held lock on the repository. This upgrade to scm-prompt gives the
user this information.

Test Plan: updated the test

Reviewers: #fbhgext, stash

Reviewed By: #fbhgext, stash

Subscribers: stash

Differential Revision: https://phab.mercurial-scm.org/D790
2017-09-22 08:31:06 -07:00
Durham Goode
8b7529b24d tests: update tests after blackbox fix 2017-09-21 23:32:55 -07:00
Jun Wu
99a01a0dbd dirsync: respect rule order
With rules of nested paths, the order of rules matters.

Note: this does not make dirsync handle recursive changes. i.e. a mirror
from path1 to path2 won't trigger a rule matching path2.

Differential Revision: https://phab.mercurial-scm.org/D770
2017-09-21 15:57:11 -07:00
Jun Wu
415f5074b3 undo: do not run undolog for every command
Previously, undolog runs for every command, which sometimes adds unwanted
noticeable overhead like `hg status` with a large obsstore. This patch makes
undo smarter to only log commands that actually write things.

This is done by making undolog only run for transactions, updates (legacy
code that does not require a transaction). Tests are changed to reflect
`hg status` does not trigger undolog, and the new code seems to work better
with chg.

Differential Revision: https://phab.mercurial-scm.org/D739
2017-09-21 14:38:43 -07:00
Mark Thomas
c68f10b4e6 infinitepush: improve notbackedup performance
The notbackedup revset predicate still has performance problems when the set of
not-backed-up changesets includes some that are completely disjoint from the
set of backed-up changesets.

Rather than trying to express it as a combination of other expressions,
implement the revset calculation directly.  This allows us to also stop as soon
as a public commit is encountered, which should be faster in all cases.

Test Plan:
Expand tests to cover more complex scenarios.  Test perf on a larger and older
checkout of a big repo.

Differential Revision: https://phab.mercurial-scm.org/D764
2017-09-21 06:06:20 -07:00
Mateusz Kwapich
abb9347d10 metaedit: make it compatible with histedit
Summary:
auto-rebasing stuff during metaedit doesn't really work well for histedit.
Let's specialcase it

Test Plan: see test

Reviewers: #fbhgext, ryanmce

Reviewed By: #fbhgext, ryanmce

Subscribers: ryanmce

Differential Revision: https://phab.mercurial-scm.org/D747
2017-09-21 05:33:54 -07:00
David Soria Parra
d6a9a2bcaa lfs: implement remotefilelog prefetch
When calling prefetch in remotefilelog, also prefetch lfs
files.

We are using the same hook mechanism that remotefilelog is already using
for LFS by having remotefilelog call into LFS.

Test Plan:
run tests on test-lfs-remotefilelog-prefetch.t

Differential Revision: https://phab.mercurial-scm.org/D732
2017-09-20 14:02:58 -07:00
Mateusz Kwapich
5c80b1b5fe [prune] advertise "hg hide"
Summary: "hg hide" is the user friendly command for hiding commits

Test Plan: ran tests

Reviewers: #fbhgext, quark

Reviewed By: #fbhgext, quark

Differential Revision: https://phab.mercurial-scm.org/D725
2017-09-20 07:55:56 -07:00
Stanislau Hlebik
8bc5444998 infinitepush: run at most one backup per hg command
Summary:
Previously we ran auto backups in txnclose hook. But commands like histedit and
rebase create many transactions, and that means that lots of backup processes
are started at the same time. That means that sometimes backup processes use
too much memory.

Instead let's start it once per command if any transaction was opened
during the command.

Test Plan:
Run unit-test.
Run histedit with autobackup enabled, and make sure just one backup process
was started.

Reviewers: #fbhgext, durham

Reviewed By: #fbhgext, durham

Subscribers: durham

Differential Revision: https://phab.mercurial-scm.org/D678
2017-09-20 07:25:52 -07:00
Durham Goode
8bb86ab225 shallowbundle: handle changegroup3
Upstream has changed local bundles to use the highest available changegroup
version, which means we're using changegroup3 for strips now. So we need to
handle that in shallowbundle.
2017-09-19 16:48:19 -07:00
Durham Goode
9140192e73 tests: update with upstream orig changes 2017-09-18 19:24:49 -07:00
Mihails Smolins
cb788cc931 remotefilelog: create delay for background prefetches
Summary:
This functionality allows to add delays between background prefetches after
operations that change the working copy parent. By default background
prefetches will be run no often than every 2 minutes, but this is configurable.
This allows to reduce the load on CPU(because prefetch is followed by repack).

Test Plan:
Tested manually on fbsource repo by running hg co bookmark several
times and ensuring that only 1 background prefetch is running if 2 minute
timeout has not expired.

Reviewers: durham, simonfar, ryanmce, #fbhgext

Reviewed By: simonfar, #fbhgext

Differential Revision: https://phab.mercurial-scm.org/D712
2017-09-15 07:28:07 -07:00