|
proxygen
|
#include <thread>#include <folly/MPMCQueue.h>#include <folly/executors/DrivableExecutor.h>#include <folly/executors/InlineExecutor.h>#include <folly/executors/ManualExecutor.h>#include <folly/futures/Future.h>#include <folly/portability/GTest.h>#include <folly/synchronization/Baton.h>Go to the source code of this file.
Classes | |
| struct | ManualWaiter |
| struct | ViaFixture |
| struct | PriorityExecutor |
| class | ThreadExecutor |
| Simple executor that does work in another thread. More... | |
| class | DummyDrivableExecutor |
Functions | |
| TEST (Via, exceptionOnLaunch) | |
| TEST (Via, thenValue) | |
| TEST (Via, thenFuture) | |
| static Future< std::string > | doWorkStatic (Try< std::string > &&t) |
| TEST (Via, thenFunction) | |
| TEST_F (ViaFixture, threadHops) | |
| TEST_F (ViaFixture, chainVias) | |
| TEST_F (ViaFixture, bareViaAssignment) | |
| TEST_F (ViaFixture, viaAssignment) | |
| TEST (Via, chain1) | |
| TEST (Via, chain3) | |
| TEST (Via, priority) | |
| TEST_F (ViaFixture, chainX1) | |
| TEST_F (ViaFixture, chainX3) | |
| TEST (Via, then2) | |
| TEST (Via, then2Variadic) | |
| TEST (Via, viaThenGetWasRacy) | |
| TEST (Via, callbackRace) | |
| TEST (Via, getVia) | |
| TEST (Via, SimpleTimedGetVia) | |
| TEST (Via, getTryVia) | |
| TEST (Via, SimpleTimedGetTryVia) | |
| TEST (Via, waitVia) | |
| TEST (Via, viaRaces) | |
| TEST (Via, viaDummyExecutorFutureSetValueFirst) | |
| TEST (Via, viaDummyExecutorFutureSetCallbackFirst) | |
| TEST (Via, viaExecutorDiscardsTaskFutureSetValueFirst) | |
| TEST (Via, viaExecutorDiscardsTaskFutureSetCallbackFirst) | |
| TEST (ViaFunc, liftsVoid) | |
| TEST (ViaFunc, value) | |
| TEST (ViaFunc, exception) | |
| TEST (ViaFunc, future) | |
| TEST (ViaFunc, semi_future) | |
| TEST (ViaFunc, voidFuture) | |
| TEST (ViaFunc, isSticky) | |
| TEST (ViaFunc, moveOnly) | |
| TEST (ViaFunc, valueKeepAlive) | |
| TEST (ViaFunc, thenValueKeepAlive) | |
|
static |
Definition at line 95 of file ViaTest.cpp.
References folly::makeFuture(), and folly::pushmi::detail::t.
Referenced by TEST().
| TEST | ( | Via | , |
| exceptionOnLaunch | |||
| ) |
| TEST | ( | Via | , |
| thenValue | |||
| ) |
Definition at line 81 of file ViaTest.cpp.
References EXPECT_TRUE, folly::makeFuture(), folly::gen::move, and folly::pushmi::detail::t.
| TEST | ( | Via | , |
| thenFuture | |||
| ) |
Definition at line 89 of file ViaTest.cpp.
References EXPECT_TRUE, folly::makeFuture(), and folly::pushmi::detail::t.
| TEST | ( | Via | , |
| thenFunction | |||
| ) |
Definition at line 99 of file ViaTest.cpp.
References doWork(), doWorkStatic(), EXPECT_EQ, f, folly::makeFuture(), string, and folly::pushmi::detail::t.
| TEST | ( | Via | , |
| chain1 | |||
| ) |
Definition at line 174 of file ViaTest.cpp.
References EXPECT_EQ, and folly::makeFuture().
| TEST | ( | Via | , |
| chain3 | |||
| ) |
Definition at line 178 of file ViaTest.cpp.
References count, EXPECT_EQ, f, folly::makeFuture(), folly::gen::move, and string.
| TEST | ( | Via | , |
| priority | |||
| ) |
Definition at line 225 of file ViaTest.cpp.
References PriorityExecutor::count0, PriorityExecutor::count1, PriorityExecutor::count2, exe, EXPECT_EQ, folly::Executor::HI_PRI, folly::Executor::LO_PRI, and folly::via().
| TEST | ( | Via | , |
| then2 | |||
| ) |
Definition at line 273 of file ViaTest.cpp.
References a, b, c, EXPECT_FALSE, EXPECT_TRUE, folly::ManualExecutor::run(), and folly::via().
| TEST | ( | Via | , |
| then2Variadic | |||
| ) |
Definition at line 297 of file ViaTest.cpp.
References a, EXPECT_FALSE, EXPECT_TRUE, f, folly::foo, testing::gmock_matchers_test::foo, folly::makeFuture(), folly::ManualExecutor::run(), and x.
| TEST | ( | Via | , |
| viaThenGetWasRacy | |||
| ) |
Definition at line 351 of file ViaTest.cpp.
References ASSERT_TRUE, EXPECT_EQ, val, folly::via(), and x.
| TEST | ( | Via | , |
| callbackRace | |||
| ) |
Definition at line 361 of file ViaTest.cpp.
References ThreadExecutor::add(), folly::collectAll(), ThreadExecutor::waitForStartup(), and x.
| TEST | ( | Via | , |
| getVia | |||
| ) |
Definition at line 395 of file ViaTest.cpp.
References EXPECT_FALSE, EXPECT_TRUE, f, folly::makeFuture(), DummyDrivableExecutor::ran, folly::via(), and x.
| TEST | ( | Via | , |
| SimpleTimedGetVia | |||
| ) |
Definition at line 418 of file ViaTest.cpp.
References EXPECT_THROW, f, and folly::Promise< T >::getFuture().
| TEST | ( | Via | , |
| getTryVia | |||
| ) |
Definition at line 425 of file ViaTest.cpp.
References EXPECT_EQ, EXPECT_FALSE, EXPECT_TRUE, f, folly::makeFuture(), DummyDrivableExecutor::ran, folly::pushmi::detail::t, folly::via(), and x.
| TEST | ( | Via | , |
| SimpleTimedGetTryVia | |||
| ) |
Definition at line 451 of file ViaTest.cpp.
References EXPECT_THROW, f, and folly::Promise< T >::getFuture().
| TEST | ( | Via | , |
| waitVia | |||
| ) |
Definition at line 458 of file ViaTest.cpp.
References EXPECT_FALSE, EXPECT_TRUE, f, folly::makeFuture(), DummyDrivableExecutor::ran, folly::via(), and x.
| TEST | ( | Via | , |
| viaRaces | |||
| ) |
Definition at line 481 of file ViaTest.cpp.
References EXPECT_EQ, folly::Promise< T >::getFuture(), folly::ManualExecutor::run(), folly::Promise< T >::setValue(), and x.
| TEST | ( | Via | , |
| viaDummyExecutorFutureSetValueFirst | |||
| ) |
Definition at line 504 of file ViaTest.cpp.
References c, EXPECT_THROW, folly::Promise< T >::getFuture(), folly::makeFuture(), folly::gen::move, and x.
| TEST | ( | Via | , |
| viaDummyExecutorFutureSetCallbackFirst | |||
| ) |
Definition at line 522 of file ViaTest.cpp.
References c, EXPECT_THROW, folly::Promise< T >::getFuture(), folly::gen::move, folly::Promise< T >::setValue(), and x.
| TEST | ( | Via | , |
| viaExecutorDiscardsTaskFutureSetValueFirst | |||
| ) |
Definition at line 542 of file ViaTest.cpp.
References c, folly::ManualExecutor::clear(), EXPECT_THROW, folly::Promise< T >::getFuture(), folly::makeFuture(), folly::gen::move, and x.
| TEST | ( | Via | , |
| viaExecutorDiscardsTaskFutureSetCallbackFirst | |||
| ) |
Definition at line 565 of file ViaTest.cpp.
References c, folly::ManualExecutor::clear(), EXPECT_THROW, folly::Promise< T >::getFuture(), folly::gen::move, folly::Promise< T >::setValue(), and x.
| TEST | ( | ViaFunc | , |
| liftsVoid | |||
| ) |
Definition at line 590 of file ViaTest.cpp.
References count, EXPECT_EQ, f, folly::ManualExecutor::run(), folly::via(), and x.
| TEST | ( | ViaFunc | , |
| value | |||
| ) |
Definition at line 600 of file ViaTest.cpp.
References EXPECT_EQ, folly::via(), and x.
| TEST | ( | ViaFunc | , |
| exception | |||
| ) |
Definition at line 605 of file ViaTest.cpp.
References EXPECT_THROW, folly::via(), and x.
| TEST | ( | ViaFunc | , |
| future | |||
| ) |
Definition at line 612 of file ViaTest.cpp.
References EXPECT_EQ, folly::makeFuture(), folly::via(), and x.
| TEST | ( | ViaFunc | , |
| semi_future | |||
| ) |
Definition at line 617 of file ViaTest.cpp.
References EXPECT_EQ, folly::makeSemiFuture(), folly::via(), and x.
| TEST | ( | ViaFunc | , |
| voidFuture | |||
| ) |
Definition at line 622 of file ViaTest.cpp.
References count, EXPECT_EQ, folly::via(), and x.
| TEST | ( | ViaFunc | , |
| isSticky | |||
| ) |
Definition at line 629 of file ViaTest.cpp.
References count, EXPECT_EQ, f, folly::gen::move, folly::ManualExecutor::run(), folly::via(), and x.
| TEST | ( | ViaFunc | , |
| moveOnly | |||
| ) |
Definition at line 642 of file ViaTest.cpp.
References EXPECT_EQ, folly::gen::move, folly::via(), and x.
| TEST | ( | ViaFunc | , |
| valueKeepAlive | |||
| ) |
Definition at line 649 of file ViaTest.cpp.
References EXPECT_EQ, folly::getKeepAliveToken(), folly::via(), and x.
| TEST | ( | ViaFunc | , |
| thenValueKeepAlive | |||
| ) |
Definition at line 654 of file ViaTest.cpp.
References EXPECT_EQ, folly::getKeepAliveToken(), folly::via(), and x.
| TEST_F | ( | ViaFixture | , |
| threadHops | |||
| ) |
Definition at line 117 of file ViaTest.cpp.
References EXPECT_EQ, EXPECT_NE, f, folly::pushmi::detail::t, and folly::via().
| TEST_F | ( | ViaFixture | , |
| chainVias | |||
| ) |
Definition at line 132 of file ViaTest.cpp.
References EXPECT_EQ, EXPECT_NE, f, folly::makeFuture(), val, and folly::via().
| TEST_F | ( | ViaFixture | , |
| bareViaAssignment | |||
| ) |
| TEST_F | ( | ViaFixture | , |
| viaAssignment | |||
| ) |
Definition at line 167 of file ViaTest.cpp.
References f, and folly::makeFuture().
| TEST_F | ( | ViaFixture | , |
| chainX1 | |||
| ) |
Definition at line 241 of file ViaTest.cpp.
References EXPECT_EQ, and folly::makeFuture().
| TEST_F | ( | ViaFixture | , |
| chainX3 | |||
| ) |
Definition at line 249 of file ViaTest.cpp.
References count, EXPECT_EQ, EXPECT_NE, f, folly::makeFuture(), string, and folly::via().