| 106 | size_t CoroutineTest::destroy_times {0}; |
| 107 | |
| 108 | TEST_F(CoroutineTest, default_destroy_with_task) { |
| 109 | using S = P<int>; |
| 110 | { |
| 111 | auto task = [](S) -> CoroutineTask<> { |
| 112 | co_return; |
| 113 | }(S {new int}); |
| 114 | ASSERT_EQ(0, destroy_times); |
| 115 | } |
| 116 | ASSERT_EQ(1, destroy_times); |
| 117 | } |
| 118 | |
| 119 | TEST_F(CoroutineTest, task_detach_coroutine_after_submit) { |
| 120 | using S = P<::std::future<void>>; |
nothing calls this directly
no test coverage detected