proxygen
|
Public Member Functions | |
MockCodecDownstreamTest () | |
void | onWriteChain (folly::AsyncTransportWrapper::WriteCallback *callback, std::shared_ptr< IOBuf >, WriteFlags) |
~MockCodecDownstreamTest () override | |
void | SetUp () override |
template<class T > | |
void | onIngressImpl (T f) |
void | testGoaway (bool doubleGoaway, bool dropConnection) |
void | testConnFlowControlBlocked (bool timeout) |
Public Member Functions inherited from testing::Test | |
virtual | ~Test () |
virtual | ~Test () |
virtual | ~Test () |
Protected Attributes | |
EventBase | eventBase_ |
StrictMock< MockHTTPCodec > * | codec_ |
std::string | userAgent_ {"MockCodec"} |
HTTPCodec::Callback * | codecCallback_ {nullptr} |
NiceMock< MockAsyncTransport > * | transport_ |
folly::AsyncTransportWrapper::ReadCallback * | transportCb_ |
folly::HHWheelTimer::UniquePtr | transactionTimeouts_ |
StrictMock< MockController > | mockController_ |
HTTPDownstreamSession * | httpSession_ |
HTTPCodec::StreamID | pushStreamID_ {0} |
bool | reusable_ {true} |
bool | transportGood_ {true} |
bool | drainPending_ {false} |
bool | doubleGoaway_ {false} |
bool | liveGoaways_ {false} |
bool | invokeWriteSuccess_ {false} |
uint32_t | writeCount_ {0} |
std::vector< folly::AsyncTransportWrapper::WriteCallback * > | cbs_ |
Additional Inherited Members | |
Public Types inherited from testing::Test | |
typedef internal::SetUpTestCaseFunc | SetUpTestCaseFunc |
typedef internal::TearDownTestCaseFunc | TearDownTestCaseFunc |
typedef internal::SetUpTestCaseFunc | SetUpTestCaseFunc |
typedef internal::TearDownTestCaseFunc | TearDownTestCaseFunc |
typedef internal::SetUpTestCaseFunc | SetUpTestCaseFunc |
typedef internal::TearDownTestCaseFunc | TearDownTestCaseFunc |
Static Public Member Functions inherited from testing::Test | |
static void | SetUpTestCase () |
static void | TearDownTestCase () |
static bool | HasFatalFailure () |
static bool | HasNonfatalFailure () |
static bool | HasFailure () |
static void | RecordProperty (const std::string &key, const std::string &value) |
static void | RecordProperty (const std::string &key, int value) |
static void | SetUpTestCase () |
static void | TearDownTestCase () |
static bool | HasFatalFailure () |
static bool | HasNonfatalFailure () |
static bool | HasFailure () |
static void | RecordProperty (const std::string &key, const std::string &value) |
static void | RecordProperty (const std::string &key, int value) |
static void | SetUpTestCase () |
static void | TearDownTestCase () |
static bool | HasFatalFailure () |
static bool | HasNonfatalFailure () |
static bool | HasFailure () |
static void | RecordProperty (const std::string &key, const std::string &value) |
static void | RecordProperty (const std::string &key, int value) |
Protected Member Functions inherited from testing::Test | |
Test () | |
virtual void | TearDown () |
Test () | |
virtual void | TearDown () |
Test () | |
virtual void | TearDown () |
Definition at line 52 of file MockCodecDownstreamTest.cpp.
|
inline |
Definition at line 54 of file MockCodecDownstreamTest.cpp.
References testing::_, folly::IOBufQueue::append(), testing::Assign(), codec_, EXPECT_CALL, folly::getEventBase(), testing::Invoke(), testing::InvokeWithoutArgs(), kDefaultIngressSettings, proxygen::localAddr, proxygen::mockTransportInfo, onWriteChain(), proxygen::peerAddr, testing::Return(), testing::ReturnRef(), transport_, and fizz::detail::writeBuf().
|
inlineoverride |
Definition at line 153 of file MockCodecDownstreamTest.cpp.
References folly::AsyncSocketException::UNKNOWN.
|
inline |
Definition at line 167 of file MockCodecDownstreamTest.cpp.
References testing::_, codec_, folly::IOBuf::computeChainDataLength(), EXPECT_CALL, f, testing::Invoke(), and folly::detail::timeout.
|
inline |
Definition at line 142 of file MockCodecDownstreamTest.cpp.
References folly::AsyncWriter::WriteCallback::writeSuccess().
Referenced by MockCodecDownstreamTest().
|
inlineoverridevirtual |
Reimplemented from testing::Test.
Definition at line 160 of file MockCodecDownstreamTest.cpp.
void MockCodecDownstreamTest::testConnFlowControlBlocked | ( | bool | timeout | ) |
Definition at line 968 of file MockCodecDownstreamTest.cpp.
References testing::_, folly::IOBufQueue::append(), codec_, EXPECT_CALL, EXPECT_EQ, proxygen::Exception::getProxygenError(), proxygen::HTTP_HEADER_CONTENT_LENGTH, testing::Invoke(), proxygen::kErrorTimeout, proxygen::http2::kInitialWindow, makeBuf(), proxygen::makeGetRequest(), proxygen::makeResponse(), folly::gen::move, testing::Return(), uint64_t, and fizz::detail::writeBuf().
void MockCodecDownstreamTest::testGoaway | ( | bool | doubleGoaway, |
bool | dropConnection | ||
) |
Definition at line 1275 of file MockCodecDownstreamTest.cpp.
References testing::_, testing::Assign(), testing::AtLeast(), codec_, testing::DoAll(), EXPECT_CALL, EXPECT_EQ, EXPECT_FALSE, handler(), testing::Invoke(), proxygen::makeGetRequest(), folly::gen::move, testing::Return(), transport_, folly::AsyncSocketException::UNKNOWN, folly::AsyncWriter::WriteCallback::writeErr(), and folly::AsyncWriter::WriteCallback::writeSuccess().
|
protected |
Definition at line 207 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 191 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 193 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 203 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 202 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 189 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 198 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 205 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 204 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 197 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 199 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 200 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 196 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 194 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 195 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 201 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 192 of file MockCodecDownstreamTest.cpp.
|
protected |
Definition at line 206 of file MockCodecDownstreamTest.cpp.