MCPcopy Create free account
hub / github.com/David-Haim/concurrencpp / test_task_call_operator_test_5

Method test_task_call_operator_test_5

test/source/tests/task_tests.cpp:561–574  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

559}
560
561void concurrencpp::tests::test_task_call_operator_test_5() {
562 // a croutine
563 object_observer observer;
564 const auto handle = coro_function({}, observer.get_testing_stub());
565
566 assert_equal(observer.get_execution_count(), 0);
567 assert_equal(observer.get_destruction_count(), 0);
568
569 task t(handle);
570 t();
571
572 assert_equal(observer.get_execution_count(), 1);
573 assert_equal(observer.get_destruction_count(), 1);
574}
575
576void concurrencpp::tests::test_task_call_operator() {
577 test_task_call_operator_test_1();

Callers

nothing calls this directly

Calls 5

coro_functionFunction · 0.85
assert_equalFunction · 0.85
get_testing_stubMethod · 0.80
get_execution_countMethod · 0.45
get_destruction_countMethod · 0.45

Tested by

no test coverage detected