[SERVER-15457] C++ Unit test fixtures should call tearDown when they exit by exception Created: 29/Sep/14  Updated: 10/Jan/15  Resolved: 10/Jan/15

Status: Closed
Project: Core Server
Component/s: Testing Infrastructure
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Major - P3
Reporter: Andy Schwerin Assignee: Andy Schwerin
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Operating System: ALL
Participants:

 Description   

Failure to call tearDown can cause tests that would normally fail to deadlock, if tearDown releases resources that may have been acquired during the test.



 Comments   
Comment by Andy Schwerin [ 10/Jan/15 ]

I realized after trying to implement this that the system works as designed. If you need clean-up behavior in a test that raises an exception, you should put it in the harness destructor.

Generated at Thu Feb 08 03:38:05 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.