|
proxygen
|
#include <bitset>#include <future>#include <thread>#include <folly/MPMCQueue.h>#include <folly/ScopeGuard.h>#include <folly/io/async/EventBase.h>#include <folly/io/async/EventHandler.h>#include <folly/portability/GMock.h>#include <folly/portability/GTest.h>#include <folly/portability/Sockets.h>#include <sys/eventfd.h>Go to the source code of this file.
Classes | |
| class | EventHandlerMock |
| class | EventHandlerTest |
Functions | |
| void | runInThreadsAndWait (size_t nthreads, function< void(size_t)> cb) |
| void | runInThreadsAndWait (vector< function< void()>> cbs) |
| TEST_F (EventHandlerTest, simple) | |
| TEST_F (EventHandlerTest, many_concurrent_producers) | |
| TEST_F (EventHandlerTest, many_concurrent_consumers) | |
| void runInThreadsAndWait | ( | size_t | nthreads, |
| function< void(size_t)> | cb | ||
| ) |
Definition at line 34 of file EventHandlerTest.cpp.
References i, nthreads, and threads.
Referenced by runInThreadsAndWait(), and TEST_F().
| void runInThreadsAndWait | ( | vector< function< void()>> | cbs | ) |
Definition at line 44 of file EventHandlerTest.cpp.
References k, and runInThreadsAndWait().
| TEST_F | ( | EventHandlerTest | , |
| simple | |||
| ) |
Definition at line 85 of file EventHandlerTest.cpp.
References testing::_, EXPECT_CALL, EXPECT_EQ, testing::Invoke(), folly::EventBase::loop(), folly::EventHandler::registerHandler(), uint16_t, and folly::EventHandler::unregisterHandler().
Referenced by TEST_F().
| TEST_F | ( | EventHandlerTest | , |
| many_concurrent_producers | |||
| ) |
Definition at line 106 of file EventHandlerTest.cpp.
References testing::_, EXPECT_CALL, EXPECT_EQ, i, testing::Invoke(), folly::EventBase::loop(), folly::EventHandler::registerHandler(), runInThreadsAndWait(), uint16_t, and folly::EventHandler::unregisterHandler().
| TEST_F | ( | EventHandlerTest | , |
| many_concurrent_consumers | |||
| ) |
Definition at line 139 of file EventHandlerTest.cpp.
References testing::_, folly::netops::accept(), ASSERT_TRUE, folly::netops::bind(), buffer(), folly::netops::close(), folly::netops::connect(), EXPECT_CALL, EXPECT_EQ, EXPECT_TRUE, folly::netops::getsockname(), i, folly::INFO, testing::Invoke(), folly::netops::listen(), folly::EventBase::loop(), folly::pushmi::__adl::noexcept(), fizz::detail::read(), folly::netops::recv(), folly::EventHandler::registerHandler(), runInThreadsAndWait(), SCOPE_EXIT, folly::netops::send(), folly::netops::socket(), string, TEST_F(), uint16_t, folly::EventHandler::unregisterHandler(), and val.