Skip to content

Commit

Permalink
Attempting to fix shared_future test
Browse files Browse the repository at this point in the history
  • Loading branch information
hkaiser committed Aug 21, 2017
1 parent 4cb1934 commit 7a01561
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/unit/lcos/shared_future.cpp
Expand Up @@ -463,6 +463,7 @@ void promise_set_value(hpx::lcos::local::promise<int>& pi)
pi.set_value(42);
}
catch (...) {
HPX_TEST(false);
}
}

Expand All @@ -472,10 +473,11 @@ void test_wait_callback()
hpx::lcos::local::promise<int> pi;
hpx::lcos::shared_future<int> fi = pi.get_future();

fi.then(&wait_callback);
hpx::future<void> cbf = fi.then(&wait_callback);
hpx::thread t(&promise_set_value, std::ref(pi));

fi.wait();
cbf.wait();

t.join();

Expand Down

0 comments on commit 7a01561

Please sign in to comment.