ThreadsafeForwardingResult leaks tags

Bug #985613 reported by Jonathan Lange
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
testtools
Fix Released
Critical
Jonathan Lange

Bug Description

tags set in one test are local to that test. Tests that follow should know nothing about tags set in previous tests. However, once a test-local tag is set in ThreadsafeForwardingResult, that tag is set for all tests that follow.

  tsfr = ThreadsafeForwardingResult(result)
  tsfr.startTest(a)
  tsfr.tags(x, y)
  tsfr.addSuccess(a)
  tsfr.stopTest(a)
  tsfr.startTest(b)
  tsfr.addSuccess(b)
  tsfr.stopTest(b)

And 'result' receives:

  startTest(a)
  tags(x, y)
  addSuccess(a)
  stopTest(a)
  startTest(b)
  tags(x, y)
  addSuccess(b)
  stopTest(b)

Whereas it should receive:

  startTest(a)
  tags(x, y)
  addSuccess(a)
  stopTest(a)
  startTest(b)
  addSuccess(b)
  stopTest(b)

Tags: tags

Related branches

Jonathan Lange (jml)
Changed in testtools:
assignee: nobody → Jonathan Lange (jml)
Gary Poster (gary)
Changed in testtools:
status: In Progress → Fix Committed
Changed in testtools:
milestone: none → next
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.