--coverage fail when the package name is different from the project name

Bug #1298398 reported by Chmouel Boudjnah on 2014-03-27
This bug affects 1 person
Affects Status Importance Assigned to Milestone

Bug Description

On a personal blog my setup.cfg my project/software name is :

name = package-foo
packages =

my package name is actually called foo locally on my filesystem and this is what I would like to test. testrunner force it to have the package from distribution.get_name() (i.e: package name) according to this code :


Here is patch that add a new option --coverage-package-name= to be able to set it to what we want :


(I think nosetests has a similiar option as well).

Let me know what do you think so I can submit it.

Related branches

Robert Collins (lifeless) wrote :

We can do this sure. I think you'll find that pbr has taken over the setup.cfg glue though. IMBW.

Changed in testrepository:
status: New → Triaged
importance: Undecided → Wishlist
Chmouel Boudjnah (chmouel) wrote :

I think I am using pbr, I have only this with my setup.py


and this in my setup.cfg :

setup-hooks =

oh well, i'll just ping monty :) but i think this patch may still be worthwhile

Marc Abramowitz (msabramo) wrote :

Sounds like the same (or similar) issue as:


I submitted a changeset for this to pbr:


Marc Abramowitz (msabramo) wrote :

https://review.openstack.org/#/c/89205/ for pbr was merged. So it might be nice to support this in testrepository for consistency.

Marc Abramowitz (msabramo) wrote :

Monty released pbr 0.8.1 with --coverage-package-name option (thanks, Monty!)

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers