Register testr as a distutil entry point

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 is contained in:
Steve Kowalik 2014-06-11 16:21:26 +10:00
parent a38dc208cf
commit 715c59738e
2 changed files with 3 additions and 1 deletions

View File

@ -125,7 +125,7 @@ class Testr(cmd.Command):
# Use this as coverage package name
if self.coverage_package_name:
package = self.coverage_package_name
options = "--source %s --parallel-mode" % self.coverage_package_name
options = "--source %s --parallel-mode" % package
os.environ['PYTHON'] = ("coverage run %s" % options)
logger.debug("os.environ['PYTHON'] = %r", os.environ['PYTHON'])

View File

@ -36,6 +36,8 @@ warnerrors = True
[entry_points]
distutils.setup_keywords =
pbr = pbr.core:pbr
distutils.commands =
testr = pbr.testr_command:Testr
[build_sphinx]
all_files = 1