[py-dev] Testing and Coverage against different python interpreter versions

meme dough memedough at gmail.com
Sat Apr 24 16:01:02 CEST 2010


Hi,

>> I have written a new pytest coverage plugin from the ground up to
>> fully support distributed testing since both pytest and coverage
>> provide good support for doing this.  Plus it gives access to pretty
>> much everything that coverage has that I know about.
>
> Do you have a link to this at all ?
> Do you intend to maintain and support this new plugin ?

With the latest py and pytest-xdist release the master and slave can
exchange information.  Until this release I had local mods and
suggested patches.  Thanks Holger!

There are still a number of loose ends to tidy up but it's now up on
pypi and bitbucket so you can throw it into a virtualenv and take it
for a test run if you like.

http://pypi.python.org/pypi/pytest-cover/

http://bitbucket.org/memedough/pytest-cover

I will definitely be using and maintaining it.

> I'm happy to drop the one I maintain on bitbucket in favor of yours if need be.

I didn't know quite what to do about the pytest-coverage repo.  I
thought of contributing to it, however it's a complete rewrite so it's
a bit much to ask to take a patch that probably only has pytest hook
lines in common.  Then I also kind of didn't like the repo having the
figleaf history and the 1.0 tag when that latest tag was only at 0.3.
Maybe I'm just being picky and shouldn't...

Not sure it should be dropped though, it's there, stable, and probably
being used by people.  And since I didn't patch the existing one but
wrote something new it's currently unproven.

Maybe best to see how things stack up after a while, doesn't seem any
harm having options - we have figleaf too.

Lets just wait for a while - maybe we merge some things and get best of all.

>> I had not thought of the case you suggest where it may be desirable to
>> instruct the plugin to actually combine the results from each slave
>> where each slave has run all tests.
>>
>> I will consider this further.
>
> Please do as this is an important use-case ihmo (and others agree).
> (Maybe not for distributed testing, but certainly for testing a library
> against more than one supported version of python).

This is a good suggestion, I added it so you can do dist=each and use
--cover-combine-each option to get single combined report from all
slaves.

Do note however that I haven't tested on all python versions so I
probably have some work to do.  Should be alright if you're only doing
2.5 / 2.6 as your email suggested though.

:)



More information about the Pytest-dev mailing list