1 #include <tests/Checkpoint.hxx>
2 #include <libfsafe/checkpoint.hxx>
3 #include <libsex/Exception.hxx>
6 void tests::Checkpoint::passIfStatementPasses()
8 CHECKPOINT((void) true);
11 void tests::Checkpoint::wrapIfStatementThrows()
13 CHECKPOINT(throw libsex::Exception("Error!"));
16 void tests::Checkpoint::testBacktrace()
19 wrapIfStatementThrows();
20 CPPUNIT_FAIL("false positive");
21 } catch (libsex::Exception
& e
) {
22 std::string exp
= __FILE__
":13: "
23 "In 'throw libsex::Exception(\"Error!\")':\n"
25 std::stringstream act
;
27 CPPUNIT_ASSERT_EQUAL(exp
, act
.str());