template<typename E> testcase unitpp::exception_case

(const testcase& tc)

Generate a testcase that expects a specific exception from the testcase it wraps.

Documentation

Generate a testcase that expects a specific exception from the testcase it wraps. It can be used something like

testcase tc(this, "Test name", &Test::test);

add("ex", exception_case<out_of_range>(tc));

The name of the exception_case is copied from the wrapped testcase, and the exception_case will execute the tc test case and report a failure unless the out_of_range exception is generated.

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.