Re: [Zope-dev] [TIP] zope.testrunner and nose count doctests differently

2011-11-12 Thread Chris Withers
On 09/11/2011 13:17, Benji York wrote:
>> If this is the case, perhaps Manuel shouldn't do anything with
>> countTestCases? (I know it would drop the test count, but that's not
>> *that* important, right? ;-) - and at least all the test runners would
>> agree...)
>
> Meh.  Having a good count in complaint test runners is more important to
> me than having all test runners agree.  Especially since the lowest
> common denominator seems to be counting the entire file as one test.

Right, but can Manuel "do the right thing" by influencing testsRun 
rather than countTestCases?

>> PS: When are you going to move source control for Manuel over to GitHub?
>
> I have no plans to move the source.  If I did I'd probably move it to
> launchpad.net because most of the other things I work on are there
> (including work things).

Booo, the least favourite dvcs ;-)

Chris

-- 
Simplistix - Content Management, Batch Processing & Python Consulting
 - http://www.simplistix.co.uk
___
Zope-Dev maillist  -  Zope-Dev@zope.org
https://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] [TIP] zope.testrunner and nose count doctests differently

2011-11-09 Thread Benji York
On Wed, Nov 9, 2011 at 2:53 AM, Chris Withers  wrote:
> Hi Benji,
>
> On 08/11/2011 11:10, Jonathan Lange wrote:
>>> Mark has somewhat misdirected the thread here, either that or I've got in a
>>> muddle, anyway, the issue at hand is that nose ignores
>>> TestCase.countTestCases(). Any nose people know what that is?
>>
>> Not a nose person, but it's usual to report on TestResult.testsRun
>> rather than TestSuite.countTestCases. The numbers can be different
>> because one test might run multiple times or report multiple results,
>> or tests might be generated during the run that weren't available for
>> countTestCases to count.
>
> If this is the case, perhaps Manuel shouldn't do anything with
> countTestCases? (I know it would drop the test count, but that's not
> *that* important, right? ;-) - and at least all the test runners would
> agree...)

Meh.  Having a good count in complaint test runners is more important to
me than having all test runners agree.  Especially since the lowest
common denominator seems to be counting the entire file as one test.

> PS: When are you going to move source control for Manuel over to GitHub?

I have no plans to move the source.  If I did I'd probably move it to
launchpad.net because most of the other things I work on are there
(including work things).

-- 
Benji York
___
Zope-Dev maillist  -  Zope-Dev@zope.org
https://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] [TIP] zope.testrunner and nose count doctests differently

2011-11-09 Thread Chris Withers
Hi Benji,

On 08/11/2011 11:10, Jonathan Lange wrote:
>> Mark has somewhat misdirected the thread here, either that or I've got in a
>> muddle, anyway, the issue at hand is that nose ignores
>> TestCase.countTestCases(). Any nose people know what that is?
>
> Not a nose person, but it's usual to report on TestResult.testsRun
> rather than TestSuite.countTestCases. The numbers can be different
> because one test might run multiple times or report multiple results,
> or tests might be generated during the run that weren't available for
> countTestCases to count.

If this is the case, perhaps Manuel shouldn't do anything with 
countTestCases? (I know it would drop the test count, but that's not 
*that* important, right? ;-) - and at least all the test runners would 
agree...)

cheers,

Chris

PS: When are you going to move source control for Manuel over to GitHub?

-- 
Simplistix - Content Management, Batch Processing & Python Consulting
 - http://www.simplistix.co.uk
___
Zope-Dev maillist  -  Zope-Dev@zope.org
https://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] [TIP] zope.testrunner and nose count doctests differently

2011-11-08 Thread Chris Withers
Hi All,

On 07/11/2011 22:25, Michael Foord wrote:
> On 07/11/2011 19:51, Mark Sienkiewicz wrote:
>> On 11/07/11 12:53, Chris Withers wrote:
>>> The only hiccup is that nose doesn't respect a test_suite function by
>>> default, so I wrote a plugin to make it do the right thing:
>>>
>>> Nose people: any idea *why* nose doesn't respect this method?

Mark has somewhat misdirected the thread here, either that or I've got 
in a muddle, anyway, the issue at hand is that nose ignores 
TestCase.countTestCases(). Any nose people know what that is?


> unittest doesn't *require* you to write a test_suite either - the point
> of test_suite is to allow you to *customize* the set of tests that are
> collected automatically when a test module is loaded. So if you are
> providing a test_suite it is because the default automatic collection
> strategy isn't enough for you.

This is true now, but I'm pretty sure when unittest was introduced, you 
had to provide a test_suite function for test discovery to work.

Of course, that's the dim and distant past and so doesn't really matter. 
However, the fact that nose ignores a test_suite method is a bug, plain 
and simple ;-)

cheers,

Chris

-- 
Simplistix - Content Management, Batch Processing & Python Consulting
 - http://www.simplistix.co.uk
___
Zope-Dev maillist  -  Zope-Dev@zope.org
https://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope )