Skip to content

Commit

Permalink
gcc test
Browse files Browse the repository at this point in the history
  • Loading branch information
kelbon committed Aug 9, 2024
1 parent 4789590 commit 9ebd298
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/test_coroutines.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -467,6 +467,7 @@ TEST(task_start_and_detach) {
dd::scope_exit e = [&] { flag.notify_one(); };
}(flag);
task.start_and_detach();
error_if(!task.empty());
flag.wait(false);
int x = 0;
dd::task task2 = [](int& x) -> dd::task<void> {
Expand All @@ -475,9 +476,10 @@ TEST(task_start_and_detach) {
}(x);
error_if(x != 0);
std::coroutine_handle h = task2.start_and_detach(/*stop_at_end=*/true);
error_if(!task2.empty());
error_if(x != 42);
error_if(!h.done());
h.destroy();
// h.destroy();
return error_count;
}

Expand Down

0 comments on commit 9ebd298

Please sign in to comment.