Cleanup the unit tests

This commit is contained in:
Denis Blank 2018-11-26 03:21:01 +01:00
parent c5663bf1ad
commit 82dd47b463

View File

@ -121,10 +121,6 @@ TYPED_TEST(single_dimension_tests, multipath_exception_is_cancelable) {
.fail([](exception_t) -> empty_result {
//
return cancel();
})
.fail([] {
//
FAIL();
}));
ASSERT_ASYNC_INCOMPLETION(
@ -132,27 +128,15 @@ TYPED_TEST(single_dimension_tests, multipath_exception_is_cancelable) {
.fail([](exception_t) -> result<int> {
//
return cancel();
})
.fail([] {
//
FAIL();
}));
}
TYPED_TEST(single_dimension_tests, multipath_exception_is_autocanceled) {
bool caught = false;
ASSERT_ASYNC_INCOMPLETION(this->supply_exception(supply_test_exception())
.fail([&](exception_t) {
ASSERT_ASYNC_INCOMPLETION(
this->supply_exception(supply_test_exception()).fail([&](exception_t) {
EXPECT_FALSE(caught);
caught = true;
})
.then([] {
// ...
FAIL();
})
.fail([](exception_t) {
// ...
FAIL();
}));
ASSERT_TRUE(caught);
}