Added test listener to catch exceptions thrown by the framework for
testing expected exception failures.