[py-dev] Fwd: Speed of py.test compared to unittest

Carl Friedrich Bolz cfbolz at gmx.de
Tue Nov 14 23:02:16 CET 2006


Pierre Rouleau wrote:
> ---------- Forwarded message ----------
> From: Pierre Rouleau <prouleau001 at gmail.com>
> Date: Nov 14, 2006 4:18 PM
> Subject: Re: [py-dev] Speed of py.test compared to unittest
> To: Maciek Fija�kowski <fijal at genesilico.pl>
>
>
> On 11/14/06, Maciek Fija�kowski <fijal at genesilico.pl> wrote:
>> Sure. Please do.
>>
> Oh, also, as far as startup time is concerned, even though the startup
> time might be constant, a larger startup time will mask differences in
> execution time of the code under test.  Since a unit test system
> should optimally be used during development, a startup time close to 0
> will show timing impact of the code being tested as it is being
> modified.  And this might be useful during development (even though
> you might want to measure performance of the module being developed
> using other tools).

I am not quite sure I buy that argument since py.test tells you the time
that the test itself took (if you use the -v argument) or that all tests
together take (at the end of each test run). As far as I remember, these
times don't include any startup times. Yes, wall clock time of the whole
test run is quite a bad measure, but you don't have to use it anyway.

Cheers,

Carl Friedrich



More information about the Pytest-dev mailing list