Ensure that the example given in #34 compiles in the CI

* Ref #34
This commit is contained in:
Denis Blank 2020-08-10 18:29:46 +02:00
parent f57c5898eb
commit 48c6abf5f2

View File

@ -383,3 +383,16 @@ TEST(async_complete_invalidation, check_whether_frame_released) {
EXPECT_EQ(value.use_count(), 1L); EXPECT_EQ(value.use_count(), 1L);
} }
// #34 when_seq gives error on VS2019
TEST(regression_tests, msvc_14_2_vs2019_build_fix) {
ASSERT_ASYNC_COMPLETION(
cti::when_seq(0, 1, cti::make_ready_continuable(2, 3), 4, 5)
.then([](int r0, int r1, int r2, int r3, int r4) {
ASSERT_EQ(r0, 0);
ASSERT_EQ(r1, 1);
ASSERT_EQ(r2, 2);
ASSERT_EQ(r3, 3);
ASSERT_EQ(r4, 4);
}));
}