|
proxygen
|
#include <folly/io/async/ScopedEventBaseThread.h>#include <chrono>#include <string>#include <folly/Optional.h>#include <folly/io/async/EventBaseManager.h>#include <folly/portability/GTest.h>#include <folly/synchronization/Baton.h>#include <folly/system/ThreadName.h>Go to the source code of this file.
Classes | |
| class | ScopedEventBaseThreadTest |
Functions | |
| TEST_F (ScopedEventBaseThreadTest, example) | |
| TEST_F (ScopedEventBaseThreadTest, named_example) | |
| TEST_F (ScopedEventBaseThreadTest, default_manager) | |
| TEST_F (ScopedEventBaseThreadTest, custom_manager) | |
| TEST_F (ScopedEventBaseThreadTest, eb_dtor_in_io_thread) | |
| TEST_F | ( | ScopedEventBaseThreadTest | , |
| example | |||
| ) |
Definition at line 34 of file ScopedEventBaseThreadTest.cpp.
References ASSERT_TRUE, folly::ScopedEventBaseThread::getEventBase(), folly::Baton< MayBlock, Atom >::post(), folly::EventBase::runInEventBaseThread(), and folly::Baton< MayBlock, Atom >::try_wait_for().
| TEST_F | ( | ScopedEventBaseThreadTest | , |
| named_example | |||
| ) |
Definition at line 42 of file ScopedEventBaseThreadTest.cpp.
References ASSERT_EQ, ASSERT_TRUE, folly::getCurrentThreadName(), folly::ScopedEventBaseThread::getEventBase(), folly::Baton< MayBlock, Atom >::post(), folly::EventBase::runInEventBaseThread(), folly::Baton< MayBlock, Atom >::try_wait_for(), and folly::Optional< Value >::value().
| TEST_F | ( | ScopedEventBaseThreadTest | , |
| default_manager | |||
| ) |
Definition at line 60 of file ScopedEventBaseThreadTest.cpp.
References EXPECT_EQ, folly::pushmi::operators::get, folly::ScopedEventBaseThread::getEventBase(), and folly::EventBase::runInEventBaseThreadAndWait().
| TEST_F | ( | ScopedEventBaseThreadTest | , |
| custom_manager | |||
| ) |
Definition at line 69 of file ScopedEventBaseThreadTest.cpp.
References EXPECT_EQ, folly::ScopedEventBaseThread::getEventBase(), folly::EventBaseManager::getEventBase(), and folly::EventBase::runInEventBaseThreadAndWait().
| TEST_F | ( | ScopedEventBaseThreadTest | , |
| eb_dtor_in_io_thread | |||
| ) |
Definition at line 78 of file ScopedEventBaseThreadTest.cpp.
References folly::Optional< Value >::clear(), folly::Optional< Value >::emplace(), EXPECT_EQ, EXPECT_NE, folly::ScopedEventBaseThread::getEventBase(), folly::ScopedEventBaseThread::getThreadId(), and folly::EventBase::runOnDestruction().