Browse Source

Intermediate changes

robot-piglet 1 year ago
parent
commit
39357888f3
1 changed files with 6 additions and 0 deletions
  1. 6 0
      util/system/yassert_ut.cpp

+ 6 - 0
util/system/yassert_ut.cpp

@@ -32,4 +32,10 @@ Y_UNIT_TEST_SUITE(YassertTest) {
         Y_ABORT_UNLESS(true, "hi %s", "there");
         Y_ABORT_UNLESS(true);
     }
+
+    Y_UNIT_TEST(TestExceptionVerify) {
+        UNIT_ASSERT_EXCEPTION(
+            []() { Y_ABORT_UNLESS([]() {throw yexception{} << "check"; return false; }(), "hi %s", "there"); }(),
+            yexception);
+    }
 }