MCPcopy Create free account
hub / github.com/GothenburgBitFactory/taskwarrior / ok

Method ok

test/test.cpp:83–96  ·  view source on GitHub ↗

//////////////////////////////////////////////////////////////////////////

Source from the content-addressed store, hash-verified

81
82///////////////////////////////////////////////////////////////////////////////
83void UnitTest::ok(bool expression, const std::string& name, bool expfail /* = false */) {
84 ++_counter;
85
86 bool success = expression;
87
88 if (success and !expfail) {
89 ++_passed;
90 std::cout << green("ok") << " " << _counter << " - " << name << '\n';
91 } else {
92 if (success == expfail) ++_failed;
93 std::cout << red("not ok") << " " << _counter << " - " << name
94 << (expfail ? (success ? " # FIXED" : " # TODO") : "") << '\n';
95 }
96}
97
98///////////////////////////////////////////////////////////////////////////////
99void UnitTest::notok(bool expression, const std::string& name, bool expfail /* = false */) {

Callers 10

TEST_NAMEFunction · 0.80
TEST_NAMEFunction · 0.80
TEST_NAMEFunction · 0.80
TEST_NAMEFunction · 0.80
TEST_NAMEFunction · 0.80
TEST_NAMEFunction · 0.80
TEST_NAMEFunction · 0.80
TEST_NAMEFunction · 0.80
TEST_NAMEFunction · 0.80
TEST_NAMEFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected