| 926 | } |
| 927 | |
| 928 | void TCoroTest::TestPollEngines() { |
| 929 | bool defaultChecked = false; |
| 930 | for (auto engine : GetEnumAllValues<EContPoller>()) { |
| 931 | auto poller = IPollerFace::Construct(engine); |
| 932 | if (!poller) { |
| 933 | continue; |
| 934 | } |
| 935 | |
| 936 | TContExecutor exec(32000, IPollerFace::Construct(engine)); |
| 937 | |
| 938 | if (engine == EContPoller::Default) { |
| 939 | defaultChecked = true; |
| 940 | #if defined(HAVE_EPOLL_POLLER) |
| 941 | UNIT_ASSERT_VALUES_EQUAL(exec.Poller()->PollEngine(), EContPoller::Epoll); |
| 942 | #elif defined(HAVE_KQUEUE_POLLER) |
| 943 | UNIT_ASSERT_VALUES_EQUAL(exec.Poller()->PollEngine(), EContPoller::Kqueue); |
| 944 | #else |
| 945 | UNIT_ASSERT_VALUES_EQUAL(exec.Poller()->PollEngine(), EContPoller::Select); |
| 946 | #endif |
| 947 | } else { |
| 948 | UNIT_ASSERT_VALUES_EQUAL(exec.Poller()->PollEngine(), engine); |
| 949 | } |
| 950 | } |
| 951 | |
| 952 | UNIT_ASSERT(defaultChecked); |
| 953 | } |
| 954 | |
| 955 | void TCoroTest::TestPause() { |
| 956 | TContExecutor executor{1024*1024, IPollerFace::Default(), nullptr, nullptr, NCoro::NStack::EGuard::Canary, Nothing()}; |
nothing calls this directly
no test coverage detected