diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2019-08-12 17:43:09 -0400 |
---|---|---|
committer | Nat Goodspeed <nat@lindenlab.com> | 2019-08-12 17:43:09 -0400 |
commit | a5f58663c00d9d6ffa12d4b9f8cf4eeee70b4d5e (patch) | |
tree | 4655c10ed8baf9de95732f7bfbb8663e965b2a2a /indra/llcommon/tests/lleventcoro_test.cpp | |
parent | 3c552696bf8704e30c1525a4f9d4b3dd09034820 (diff) | |
parent | 4fce6dc4353dbf9ccd3c9c3aced89df72a4f3abd (diff) |
Automated merge with ssh://bitbucket.org/andreykproductengine/drtvwr-493
Diffstat (limited to 'indra/llcommon/tests/lleventcoro_test.cpp')
-rw-r--r-- | indra/llcommon/tests/lleventcoro_test.cpp | 33 |
1 files changed, 11 insertions, 22 deletions
diff --git a/indra/llcommon/tests/lleventcoro_test.cpp b/indra/llcommon/tests/lleventcoro_test.cpp index a459d17fb8..fa02d2bb1a 100644 --- a/indra/llcommon/tests/lleventcoro_test.cpp +++ b/indra/llcommon/tests/lleventcoro_test.cpp @@ -506,16 +506,10 @@ namespace tut replyName = waiter.getName0(); errorName = waiter.getName1(); WrapLLErrs capture; - try - { - result = waiter.suspendWithLog(); - debug("no exception"); - } - catch (const WrapLLErrs::FatalException& e) - { - debug(STRINGIZE("exception " << e.what())); - threw = e.what(); - } + threw = capture.catch_llerrs([&waiter, &debug](){ + result = waiter.suspendWithLog(); + debug("no exception"); + }); } END } @@ -762,18 +756,13 @@ namespace tut { LLCoroEventPumps waiter; WrapLLErrs capture; - try - { - result = waiter.postAndSuspendWithLog( - LLSDMap("value", 31)("fail", LLSD()), - immediateAPI.getPump(), "reply", "error"); - debug("no exception"); - } - catch (const WrapLLErrs::FatalException& e) - { - debug(STRINGIZE("exception " << e.what())); - threw = e.what(); - } + threw = capture.catch_llerrs( + [&waiter, &debug](){ + result = waiter.postAndSuspendWithLog( + LLSDMap("value", 31)("fail", LLSD()), + immediateAPI.getPump(), "reply", "error"); + debug("no exception"); + }); } END } |