Zope layer setup and teardown 'tests' cannot be filtered by testr

Bug #914166 reported by Graham Binns
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Launchpad itself
Triaged
High
Unassigned
Testrepository
Fix Released
Wishlist
Robert Collins
zope.testing
Invalid
Undecided
Unassigned

Bug Description

What happens:
If you run the Launchpad tests with --subunit, it will report the layer setup and teardown notices as tests, which they aren't. This leads to test count inflation, which gets very confusing for developers (especially when you're running parallel tests, which means that you add about 20 such notices per lxc instance).

Proposed solution (from lifeless):
 - Update the zope.testing subunit support so that layer setup and teardown messages are tagged with "layer".
    - already the case
 - Subunit needs to know about tags.
    - already the case
 - Testr needs to not count or record layer-tagged things as tests.
    - needs to be configurable, and is pending
 - Testr should still dump the layer-tagged messages to the raw stream on disk.
    - same as above

Sub-bugs:
 bug 914281 - noop - case of 518016
 bug 914279 - fixed
 bug 914278 - fixed
 bug 518016 - fixed

Tags: paralleltest

Related branches

Revision history for this message
Jonathan Lange (jml) wrote : Re: [Bug 914166] [NEW] Testr thinks that Zope layer setup and teardown messages are tests

On Tue, Jan 10, 2012 at 9:06 AM, Graham Binns <email address hidden> wrote:
> Public bug reported:
>
> What happens:
> If you run the Launchpad tests with --subunit, it will report the layer setup and teardown notices as tests, which they aren't. This leads to test count inflation, which gets very confusing for developers (especially when you're running parallel tests, which means that you add about 20 such notices per lxc instance).
>
> Proposed solution (from lifeless):
>  - Update the zope.testing subunit support so that layer setup and teardown messages are tagged with "layer".
>  - Subunit needs to know about tags.
>  - Testr needs to not count or record layer-tagged things as tests.
>  - Testr should still dump the layer-tagged messages to the raw stream on disk.

Some thoughts:

 * zope.testing already outputs a 'zope:layer' tag after emitting the
start of the test that represents the layer
 * It treats layers as tests to provide a place to put layer
setUp/tearDown errors
 * It would be nicer for testr to not know about layers, but rather to
achieve the same result with (not yet existing) subunit filtering
tools

jml

Revision history for this message
Graham Binns (gmb) wrote :

On 10 January 2012 10:29, Jonathan Lange <email address hidden> wrote:
> Some thoughts:
>
>  * zope.testing already outputs a 'zope:layer' tag after emitting the
> start of the test that represents the layer
>  * It treats layers as tests to provide a place to put layer
> setUp/tearDown errors
>  * It would be nicer for testr to not know about layers, but rather to
> achieve the same result with (not yet existing) subunit filtering
> tools

Yeah, we just found that :). Thanks.

Graham Binns (gmb)
Changed in zope.testing:
status: New → Invalid
Changed in launchpad:
status: Triaged → In Progress
Gary Poster (gary)
Changed in launchpad:
importance: Undecided → High
Gary Poster (gary)
description: updated
description: updated
summary: - Testr thinks that Zope layer setup and teardown messages are tests
+ Zope layer setup and teardown 'tests' cannot be filtered by testr
description: updated
description: updated
Gary Poster (gary)
Changed in launchpad:
status: In Progress → Triaged
Changed in testrepository:
status: New → Triaged
importance: Undecided → Wishlist
Changed in testrepository:
status: Triaged → Fix Committed
assignee: nobody → Robert Collins (lifeless)
milestone: none → next
Changed in testrepository:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.