These are not recommended for use in OpenStack anymore and both nose and
testr offer native setuptools commands that can be manually aliased to
'test' on a per-project basis if necessary. Deprecate with an eye to
removal in the future.
Change-Id: I753f2ffe8b223b180b8ed813d879b3a28b47a1ab
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
When using --coverage, also generate a machine-readable XML coverage
report. This is useful to build tooling around automated tracking of
coverage results.
Change-Id: Idd54ecc627896cc5eab4903658f10a344bdb1778
A "testr" entry-point was added to PBR in
I2227adf3643ffe6bcece0c7d2127d23e20d52f7a in Jun 2013. However,
testrepository had already started providing this same
disutils.commands entry-point in Jan 2013 [1].
I am not sure if it is deterministic who wins when two packages
declare the same entry-point, but at least for me, running "python
setup.py testr ..." was not calling into any of the pbr hooks. I
discovered this because I wanted to use the --coverage-package-name
argument provided by the pbr testr wrapper because to s/-/_ in dib.
The original change (I8e4bc9bb78be37b4d13f8d6c2edfe2d67554ad78)
overrides the setuptools provided "test" [2] to call testrepository
when it sees a .testr.conf file (falling back to nose for
compatability). So it seems the intention was not to add a "testr"
command, but that "test" is overridden to run testr automatically when
available.
Therefore I think that testrepository owns the distutils.command
entry-point for "testr". To avoid confusion we should remove the
duplicate entry-point here and just leave the "test" command
overrides.
I've added documentation on the test command. The testr/test split is
quite confusing, being only one letter different, so that is called
out explicitly. Comments in testr_command are updated to reflect
what's happening better. This also converts the calls in tox.ini to
use the PBR wrapper "test".
[1] 2a36806c69 (diff-2eeaed663bd0d25b7e608891384b7298R96)
[2] https://github.com/pypa/setuptools/blob/master/setuptools/command/test.py
Change-Id: I5b68f03e782fef5c45424c04cc851be5988f9019
The --coverage-package-name allows to specify
multiple packages. This change updates the doc to
reflect that.
Change-Id: Id9cfedf699c3e15b7e1c7b20531488682775462a
testr command is registered by pbr.hooks.commands if
testrepository is installed, so there is no need to
setup the entry point in setup.cfg.
Change-Id: I95aae12d1ac810b6d1d09b71f2a0d87be5ccb6ab
Closes-Bug: #1375048
Ignore H904 because it's a deprecated hacking check.
Ignore H405 because it should be fixed with a separate patch.
Change-Id: I2e3bf41474cead1a860810886791e025139cca3b
pbr contains a testr distutil command, but since it isn't registered
as an entry-point, it won't get used. Also drive-by a fix to
coverage, where we go to the trouble of setting a variable, and then
not using it.
Change-Id: I2227adf3643ffe6bcece0c7d2127d23e20d52f7a
This commit adds a new serial option to testr_command.py that when
set will run testr serially instead of running testr with the
'--parallel' flag.
Change-Id: Id49b105dc921e9acdef1a94d933719ad3a772c81
As a step towards a common interface to running tests even when we're
not in the virtualenv - make python setup.py test actually be useful.
Change-Id: I8e4bc9bb78be37b4d13f8d6c2edfe2d67554ad78