fix future_test

This commit is contained in:
tqcq 2024-04-29 20:53:04 +08:00
parent a66c5a3b7a
commit e5bd62a738

View File

@ -125,6 +125,7 @@ TEST_SUITE("future")
throw std::runtime_error("test"); throw std::runtime_error("test");
return 1; return 1;
}); });
f2.Wait();
CHECK_FALSE(f2.IsFailed()); CHECK_FALSE(f2.IsFailed());
CHECK_EQ(std::string("test"), f2.FailureReason().what()); CHECK_EQ(std::string("test"), f2.FailureReason().what());
CHECK(f2.IsFailed()); CHECK(f2.IsFailed());