Visual Assert – The Unit Testing Add-In for Visual C++
cfix – C/C++ Unit Testing for Win32 and NT
 
 

TestFixture::After

TestFixture::After
Synopsis

Method that may be overridden to implement cleanup logic. This method will be called once per test method, after the individual test method has been invoked. As such, this method should be used to clean up any state (for example, member variables) set up by tests ar a before method.

This method corresponds to after routines in the Base API

Declaration
virtual void After();
					
Remarks

This method will be called regardless of whether the test routine succeeded or not. The only situation in which the the after method is not called is when the before method of the same class has previously failed, in which case the test routine also did not run.

[Note]Note
For certain cleanup work that should occur only once per fixture (rather than once per test), use a teardown method rather than an after method.