summaryrefslogtreecommitdiff
path: root/modules/async/tests
diff options
context:
space:
mode:
Diffstat (limited to 'modules/async/tests')
-rw-r--r--modules/async/tests/immediate.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/modules/async/tests/immediate.cpp b/modules/async/tests/immediate.cpp
index a5d9b2f..5a59ccd 100644
--- a/modules/async/tests/immediate.cpp
+++ b/modules/async/tests/immediate.cpp
@@ -34,10 +34,11 @@ SAW_TEST("Immediate Conveyor Queueing"){
conveyor<int> immediately_done{val};
int passed = 0;
+ bool has_failed = false;
auto res = immediately_done.then([&passed](int a) {
passed = a;
- }).sink([](auto err){
- SAW_EXPECT(false, "No error should occur. This code path shouldn't be reachable.");
+ }).sink([&](auto err){
+ has_failed = true;
return err;
});
@@ -48,5 +49,6 @@ SAW_TEST("Immediate Conveyor Queueing"){
wait.poll();
SAW_EXPECT(passed == val, "Expected a 5 in passed value.");
+ SAW_EXPECT(!has_failed, "No error should occur in queueing");
}
}