MCPcopy Create free account
hub / github.com/boostorg/filesystem / cpp_main

Function cpp_main

test/sample_test.cpp:39–62  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

37// cpp_main ----------------------------------------------------------------//
38
39int cpp_main(int argc, char* argv[])
40{
41 if (argc > 1 && std::strcmp(argv[1], "--no-cleanup") == 0)
42 cleanup = false;
43
44 // Test cases go after this block of comments
45 // Use test case macros from boost/core/lightweight_test.hpp:
46 //
47 // BOOST_TEST(predicate); // test passes if predicate evaluates to true
48 // BOOST_TEST_EQ(x, y); // test passes if x == y
49 // BOOST_TEST_NE(x, y); // test passes if x != y
50 // BOOST_ERROR(msg); // test fails, outputs msg
51 // Examples:
52 // BOOST_TEST(path("f00").size() == 3); // test passes
53 // BOOST_TEST_EQ(path("f00").size(), 3); // test passes
54 // BOOST_MSG("Oops!"); // test fails, outputs "Oops!"
55
56 if (cleanup)
57 {
58 // Remove any test files or directories here
59 }
60
61 return ::boost::report_errors();
62}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected