[MERGE] Add --coverage option to selftest

Aaron Bentley aaron.bentley at utoronto.ca
Thu Dec 6 13:49:38 GMT 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Andrew Bennetts wrote:
>>> Maybe it would be better to install the trace hook
>>> earlier, in bzrlib.tests.selftest rather than bzrlib.tests.run_suite, to avoid
>>> this problem?
>> As I read it, the coverage doesn't necessarily have to be tied to the
>> test suite at all.  It could just be a global option, like our profiling
>> options.
> 
> That's an interesting idea.  I was mainly interested in using it as a cheap way
> to check my assumptions about what tests are and aren't exercising are correct,
> but if you think it'd be useful as a global option then I'd be happy to see it
> become one.  I guess it in that case it should hook in at the same point as our
> lsprof option.  And as you point out, that'd solve the “import/def/class
> statements aren't tracked” problem...

I don't know if coverage would be useful by itself.  Possibly it could
be a debugging tool.  But it seemed like the most straightforward way to
fix the import/def/class issue, and I can't think of any arguments
against it.

Aaron


P.S. Oops.  Didn't mean to take this off-list.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHV/3y0F+nu1YWqI0RAnJCAJ9ZghrEo9UH7ySVX1NnREc0v7leIgCdFBjd
WXBFj08UWH3vDe3lc37cDpo=
=dBYM
-----END PGP SIGNATURE-----



More information about the bazaar mailing list