OK. Thank you for the idea. You will be happy :)

--
Thadeus





On Wed, May 5, 2010 at 2:00 PM, Jonathan Lundell <[email protected]> wrote:
> On May 5, 2010, at 9:13 AM, Thadeus Burgess wrote:
>
>> It supports nosetests which includes a coverage plugin. I will look
>> into adding the option stand-alone so you do not need nosetests.
>
> Nosetests works for me just fine; in fact it's preferable.
>
>>
>> The problem is that there is no way to determine how much "coverage"
>> you have in a web2py app. It will include the coverage of "gluon + all
>> apps", which is not what you want I don't think. I have attempted and
>> do not see any way around this, it is a limitation in web2py that will
>> now allow for proper coverage testing.
>
> In my current unit test, which calls coverage directly, I generate the report 
> like this:
>
> cov.report(file=open('coverage.report','w'), 
> omit_prefixes=list(('gluon','/path/to/tests')))
>
> That is, I exclude gluon and the unit test directory from the report, which 
> seems to do the trick just fine. I'm pretty sure you can do the same thing 
> via the nose plugin, but I haven't tried.
>
>>
>> The requirements for the script are:
>>
>> A) Source installation of web2py, given how it must execute and locate
>> test files
>> B) A runner script to actually start the tests. Since it relies on the
>> path to [A]
>
>
>

Reply via email to