Mercurial > hg
annotate contrib/chg/README @ 37338:cbc4425e81b5
tests: conditionalize tests based on presence of revlogs for files
~85 tests don't like our non-revlog file store for various reasons.
This commit introduces hghave functionality for declaring and querying
repository features. By default, we assume repositories have
revlog-based file storage. But if the HGREPOFEATURES environment
variable is set, we can override the default set of repository
features. If you run the test harness with our simplestorerepo
extension and an environment variable set to the proper value, you
can override the hghave defaults to agree with simplestorerepo's
version of reality.
Various tests have been modified so behavior dependent on revlog-based
file storage is marked as such.
This fixes a handful of test failures with our custom file storage
extension. But dozens remain. The point of this commit is to demonstrate
how tests will need to be modified to account for custom storage
implementations.
TBH, I'm not convinced hghave is the proper layer for repository
feature detection. I /think/ we'll eventually want something in
run-tests.py itself. But that would require inventing a new primitive
in the test harness. This is all very alpha at the moment. So I think
hghave is an acceptable place to hang this feature detection. I think
the right time to be thinking about integrating this into run-tests.py
is *after* we have a stable alternate storage implementation in core.
For now, let's try to make progress towards the idea of an alternate
storage backend.
Differential Revision: https://phab.mercurial-scm.org/D3030
author | Gregory Szorc <gregory.szorc@gmail.com> |
---|---|
date | Tue, 03 Apr 2018 18:15:24 -0700 |
parents | 66d41c9e9222 |
children | 4c8d9b53b1c7 |
rev | line source |
---|---|
28060 | 1 cHg |
2 === | |
3 | |
4 A fast client for Mercurial command server running on Unix. | |
5 | |
6 Install: | |
7 | |
8 $ make | |
9 $ make install | |
10 | |
11 Usage: | |
12 | |
13 $ chg help # show help of Mercurial | |
14 $ alias hg=chg # replace hg command | |
15 $ chg --kill-chg-daemon # terminate background server | |
16 | |
17 Environment variables: | |
18 | |
19 Although cHg tries to update environment variables, some of them cannot be | |
20 changed after spawning the server. The following variables are specially | |
21 handled: | |
22 | |
28454 | 23 * configuration files are reloaded automatically by default. |
28060 | 24 * CHGHG or HG specifies the path to the hg executable spawned as the |
25 background command server. | |
26 | |
27 The following variables are available for testing: | |
28 | |
29 * CHGDEBUG enables debug messages. | |
30 * CHGSOCKNAME specifies the socket path of the background cmdserver. | |
29345 | 31 * CHGTIMEOUT specifies how many seconds chg will wait before giving up |
29357
66d41c9e9222
chg: change default connect timeout to 60 seconds
Jun Wu <quark@fb.com>
parents:
29345
diff
changeset
|
32 connecting to a cmdserver. If it is 0, chg will wait forever. Default: 60 |