I want to run CppUnit regresion tests for the nightly build and automatically send an email to the "owner" of a failed test (it might not be his code, but he owns the fucntionality besing tested).

I imagine that I need to extand a particular class which represnts a test (fixture?), and add a member to hold a string with an email address which can be assigned in each test case.

Then I need to find the code which handles a failed test and add a line to send an email to the functional owner of the test (and maybe the project manager, etc). I may take this further in future, updating a wiki page, etc - but I don't know where to add the code.

Can anyone help on these two questions? Thanks in advance.