MCPcopy Create free account
hub / github.com/boostorg/stacktrace / test_trace_from_exception

Function test_trace_from_exception

test/test_from_exception.cpp:62–72  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

60}
61
62BOOST_NOINLINE BOOST_SYMBOL_VISIBLE void test_trace_from_exception() {
63 // const test_no_pending_on_finish guard{}; // something strange
64 try {
65 in_test_throw_1("testing basic");
66 } catch (const std::exception&) {
67 auto trace = stacktrace::from_current_exception();
68 BOOST_TEST(trace);
69 std::cout << "Tarce in test_trace_from_exception(): " << trace << '\n';
70 BOOST_TEST(to_string(trace).find("in_test_throw_1") != std::string::npos);
71 }
72}
73
74BOOST_NOINLINE BOOST_SYMBOL_VISIBLE void test_after_other_exception() {
75 try {

Callers 1

mainFunction · 0.85

Calls 3

from_current_exceptionFunction · 0.85
to_stringFunction · 0.85
in_test_throw_1Function · 0.70

Tested by

no test coverage detected