A Scalable, User-Friendly Source Control System.
Go to file
Gregory Szorc 99a062e473 run-tests: mechanism to report exceptions during test execution
Sometimes when running tests you introduce a ton of exceptions.
The most extreme example of this is running Mercurial with Python 3,
which currently spews thousands of exceptions when running the test
harness.

This commit adds an opt-in feature to run-tests.py to aggregate
exceptions encountered by `hg` when running tests.

When --exceptions is used, the test harness enables the
"logexceptions" extension in the test environment. This extension
wraps the Mercurial function to handle exceptions and writes
information about the exception to a random filename in a directory
defined by the test harness via an environment variable. At the
end of the test harness, these files are parsed, aggregated, and
a list of all unique Mercurial frames triggering exceptions is
printed in order of frequency.

This feature is intended to aid Python 3 development. I've only
really tested it on Python 3. There is no shortage of improvements
that could be made. e.g. we could write a separate file containing
the exception report - maybe even an HTML report. We also don't
capture which tests demonstrate the exceptions, so there's no turnkey
way to test whether a code change made an exception disappear.
Perfect is the enemy of good. I think the current patch is useful
enough to land. Whoever uses it can send patches to imprve its
usefulness.

Differential Revision: https://phab.mercurial-scm.org/D1477
2017-11-20 23:02:32 -08:00
contrib contrib: improve check-code ban on $LOCALIP in output without (glob) 2017-11-29 17:06:45 -05:00
doc build: make install in "/doc" failed if the destination dir contained spaces 2017-10-11 01:19:48 +02:00
hgdemandimport demandimportpy3: update to pass import checker 2017-08-22 14:14:34 -04:00
hgext merge with stable 2017-12-01 15:21:05 -06:00
hgext3rd extensions: also search for extension in the 'hgext3rd' package 2016-03-11 10:30:08 +00:00
i18n i18n-pt_BR: synchronized with f1d5a55d6a57 2017-11-21 13:50:25 -02:00
mercurial merge with stable 2017-12-01 15:21:05 -06:00
tests run-tests: mechanism to report exceptions during test execution 2017-11-20 23:02:32 -08:00
.clang-format clang-format: configuration for the clang-format source formatter 2015-01-24 17:04:25 -05:00
.editorconfig mercurial: add editorconfig 2016-04-05 18:10:33 +01:00
.hgignore run-tests: mechanism to report exceptions during test execution 2017-11-20 23:02:32 -08:00
.hgsigs Added signature for changeset f51ae48a3fd9 2017-12-01 13:49:47 -06:00
.jshintrc hgweb: add .jshintrc with some basic rules 2017-11-22 22:18:06 +08:00
CONTRIBUTING contributing: add new file with a pointer to the wiki 2016-10-08 10:39:00 -04:00
CONTRIBUTORS Add note to CONTRIBUTORS file 2007-11-07 21:10:30 -06:00
COPYING COPYING: refresh with current address from fsf.org 2011-06-02 11:17:02 -05:00
hg dispatch: move initialization of sys.std* files 2017-10-02 07:18:24 +01:00
hgeditor spelling: trivial spell checking 2015-10-17 00:58:46 +02:00
hgweb.cgi urls: bulk-change primary website URLs 2015-09-30 15:43:49 -05:00
Makefile makefile: put format-c into .PHONY targets 2017-10-26 11:58:55 +08:00
README.rst doc: rename README to README.rst 2017-09-26 08:37:17 +02:00
setup.py setup: add hgext.lfs to list of Python packages 2017-11-20 18:00:02 -05:00

Mercurial
=========

Mercurial is a fast, easy to use, distributed revision control tool
for software developers.

Basic install::

 $ make            # see install targets
 $ make install    # do a system-wide install
 $ hg debuginstall # sanity-check setup
 $ hg              # see help

Running without installing::

 $ make local      # build for inplace usage
 $ ./hg --version  # should show the latest version

See https://mercurial-scm.org/ for detailed installation
instructions, platform-specific notes, and Mercurial user information.