| 8 | Y_UNIT_TEST_SUITE(TestContext) { |
| 9 | template <class F> |
| 10 | static TContClosure Wrap(F& f) { |
| 11 | struct TW: public ITrampoLine { |
| 12 | inline TW(F* ff) noexcept |
| 13 | : F_(ff) |
| 14 | { |
| 15 | } |
| 16 | |
| 17 | void DoRun() override { |
| 18 | (*F_)(); |
| 19 | } |
| 20 | |
| 21 | F* F_; |
| 22 | char Buf[1000000]; |
| 23 | }; |
| 24 | |
| 25 | static TDeque<TW> w; |
| 26 | |
| 27 | auto& tw = w.emplace_back(&f); |
| 28 | |
| 29 | return {&tw, TArrayRef(tw.Buf, sizeof(tw.Buf))}; |
| 30 | } |
| 31 | |
| 32 | Y_UNIT_TEST(TestExceptionSafety) { |
| 33 | TExceptionSafeContext main; |
no test coverage detected