proxygen
fizz::client::test::MockAsyncFizzClient Class Reference

#include <Mocks.h>

Inheritance diagram for fizz::client::test::MockAsyncFizzClient:
fizz::client::AsyncFizzClientT< SM > fizz::AsyncFizzBase folly::AsyncSocket::ConnectCallback folly::WriteChainAsyncTransportWrapper< folly::AsyncTransportWrapper > folly::AsyncWriter::WriteCallback folly::AsyncReader::ReadCallback folly::DecoratedAsyncTransportWrapper< folly::AsyncTransportWrapper > folly::AsyncTransportWrapper folly::AsyncTransport folly::AsyncReader folly::AsyncWriter folly::DelayedDestruction folly::AsyncSocketBase folly::DelayedDestructionBase

Public Member Functions

 MockAsyncFizzClient ()
 
 MOCK_METHOD5 (connect, void(HandshakeCallback *, std::shared_ptr< const CertificateVerifier >, folly::Optional< std::string >, folly::Optional< std::string >, std::chrono::milliseconds))
 
 MOCK_METHOD0 (close, void())
 
 MOCK_METHOD0 (closeWithReset, void())
 
 MOCK_METHOD0 (closeNow, void())
 
- Public Member Functions inherited from fizz::client::AsyncFizzClientT< SM >
 AsyncFizzClientT (folly::AsyncTransportWrapper::UniquePtr socket, std::shared_ptr< const FizzClientContext > fizzContext, const std::shared_ptr< ClientExtensions > &extensions=nullptr)
 
 AsyncFizzClientT (folly::EventBase *eventBase, std::shared_ptr< const FizzClientContext > fizzContext, const std::shared_ptr< ClientExtensions > &extensions=nullptr)
 
virtual void connect (HandshakeCallback *callback, std::shared_ptr< const CertificateVerifier > verifier, folly::Optional< std::string > sni, folly::Optional< std::string > pskIdentity, std::chrono::milliseconds=std::chrono::milliseconds(0))
 
virtual void connect (const folly::SocketAddress &connectAddr, folly::AsyncSocket::ConnectCallback *callback, std::shared_ptr< const CertificateVerifier > verifier, folly::Optional< std::string > sni, folly::Optional< std::string > pskIdentity, std::chrono::milliseconds totalTimeout=std::chrono::milliseconds(0), std::chrono::milliseconds socketTimeout=std::chrono::milliseconds(0), const folly::AsyncSocket::OptionMap &options=folly::AsyncSocket::emptyOptionMap, const folly::SocketAddress &bindAddr=folly::AsyncSocket::anyAddress())
 
virtual void connect (HandshakeCallback *callback, folly::Optional< std::string > hostname, std::chrono::milliseconds=std::chrono::milliseconds(0))
 
bool good () const override
 
bool readable () const override
 
bool connecting () const override
 
bool error () const override
 
folly::ssl::X509UniquePtr getPeerCert () const override
 
const X509 * getSelfCert () const override
 
const CertgetPeerCertificate () const override
 
const CertgetSelfCertificate () const override
 
bool isReplaySafe () const override
 
void setReplaySafetyCallback (folly::AsyncTransport::ReplaySafetyCallback *callback) override
 
std::string getApplicationProtocol () const noexceptoverride
 
void close () override
 
void closeWithReset () override
 
void closeNow () override
 
void setEarlyDataRejectionPolicy (EarlyDataRejectionPolicy policy)
 
const StategetState () const
 
folly::Optional< CipherSuitegetCipher () const override
 
std::vector< SignatureSchemegetSupportedSigSchemes () const override
 
Buf getEkm (folly::StringPiece label, const Buf &context, uint16_t length) const override
 
Buf getEarlyEkm (folly::StringPiece label, const Buf &context, uint16_t length) const
 
bool pskResumed () const
 
- Public Member Functions inherited from fizz::AsyncFizzBase
 AsyncFizzBase (folly::AsyncTransportWrapper::UniquePtr transport)
 
 ~AsyncFizzBase () override
 
ReadCallbackgetReadCallback () const override
 
void setReadCB (ReadCallback *callback) override
 
void writeChain (folly::AsyncTransportWrapper::WriteCallback *callback, std::unique_ptr< folly::IOBuf > &&buf, folly::WriteFlags flags=folly::WriteFlags::NONE) override
 
size_t getAppBytesWritten () const override
 
size_t getAppBytesReceived () const override
 
void destroy () override
 
std::string getSecurityProtocol () const override
 
void attachTimeoutManager (folly::TimeoutManager *manager)
 
void detachTimeoutManager ()
 
void attachEventBase (folly::EventBase *eventBase) override
 
void detachEventBase () override
 
bool isDetachable () const override
 
- Public Member Functions inherited from folly::WriteChainAsyncTransportWrapper< folly::AsyncTransportWrapper >
void write (folly::AsyncTransportWrapper::WriteCallback *callback, const void *buf, size_t bytes, folly::WriteFlags flags=folly::WriteFlags::NONE) override
 
void writev (folly::AsyncTransportWrapper::WriteCallback *callback, const iovec *vec, size_t count, folly::WriteFlags flags=folly::WriteFlags::NONE) override
 
- Public Member Functions inherited from folly::DecoratedAsyncTransportWrapper< folly::AsyncTransportWrapper >
 DecoratedAsyncTransportWrapper (typename folly::AsyncTransportWrapper::UniquePtr transport)
 
const AsyncTransportWrappergetWrappedTransport () const override
 
ReadCallbackgetReadCallback () const override
 
void setReadCB (folly::AsyncTransportWrapper::ReadCallback *callback) override
 
folly::EventBasegetEventBase () const override
 
void attachEventBase (folly::EventBase *eventBase) override
 
void close () override
 
void closeNow () override
 
void closeWithReset () override
 
bool connecting () const override
 
void detachEventBase () override
 
bool error () const override
 
size_t getAppBytesReceived () const override
 
size_t getAppBytesWritten () const override
 
void getLocalAddress (folly::SocketAddress *address) const override
 
void getPeerAddress (folly::SocketAddress *address) const override
 
folly::ssl::X509UniquePtr getPeerCert () const override
 
size_t getRawBytesReceived () const override
 
size_t getRawBytesWritten () const override
 
uint32_t getSendTimeout () const override
 
bool good () const override
 
bool isDetachable () const override
 
bool isEorTrackingEnabled () const override
 
bool readable () const override
 
bool writable () const override
 
void setEorTracking (bool track) override
 
void setSendTimeout (uint32_t timeoutInMs) override
 
void shutdownWrite () override
 
void shutdownWriteNow () override
 
std::string getApplicationProtocol () const noexceptoverride
 
std::string getSecurityProtocol () const override
 
bool isReplaySafe () const override
 
void setReplaySafetyCallback (folly::AsyncTransport::ReplaySafetyCallback *callback) override
 
const AsyncTransportCertificategetPeerCertificate () const override
 
const AsyncTransportCertificategetSelfCertificate () const override
 
- Public Member Functions inherited from folly::AsyncTransportWrapper
template<class T >
const TgetUnderlyingTransport () const
 
template<class T >
TgetUnderlyingTransport ()
 
- Public Member Functions inherited from folly::AsyncTransport
virtual bool isPending () const
 
SocketAddress getLocalAddress () const
 
void getAddress (SocketAddress *address) const override
 
SocketAddress getPeerAddress () const
 
- Public Member Functions inherited from folly::DelayedDestruction
bool getDestroyPending () const
 
- Public Member Functions inherited from folly::DelayedDestructionBase
virtual ~DelayedDestructionBase ()=default
 
- Public Member Functions inherited from folly::AsyncSocketBase
virtual ~AsyncSocketBase ()=default
 

Additional Inherited Members

- Public Types inherited from fizz::client::AsyncFizzClientT< SM >
using UniquePtr = std::unique_ptr< AsyncFizzClientT, folly::DelayedDestruction::Destructor >
 
- Public Types inherited from fizz::AsyncFizzBase
using UniquePtr = std::unique_ptr< AsyncFizzBase, folly::DelayedDestruction::Destructor >
 
using ReadCallback = folly::AsyncTransportWrapper::ReadCallback
 
- Public Types inherited from folly::AsyncTransportWrapper
using UniquePtr = std::unique_ptr< AsyncTransportWrapper, Destructor >
 
using ReadCallback = AsyncReader::ReadCallback
 
using WriteCallback = AsyncWriter::WriteCallback
 
- Public Types inherited from folly::AsyncTransport
typedef std::unique_ptr< AsyncTransport, DestructorUniquePtr
 
- Protected Member Functions inherited from fizz::client::AsyncFizzClientT< SM >
void writeAppData (folly::AsyncTransportWrapper::WriteCallback *callback, std::unique_ptr< folly::IOBuf > &&buf, folly::WriteFlags flags=folly::WriteFlags::NONE) override
 
void transportError (const folly::AsyncSocketException &ex) override
 
void transportDataAvailable () override
 
- Protected Member Functions inherited from fizz::AsyncFizzBase
virtual void startTransportReads ()
 
virtual void startHandshakeTimeout (std::chrono::milliseconds)
 
virtual void cancelHandshakeTimeout ()
 
virtual void deliverAppData (std::unique_ptr< folly::IOBuf > buf)
 
virtual void deliverError (const folly::AsyncSocketException &ex, bool closeTransport=true)
 
- Protected Member Functions inherited from folly::DecoratedAsyncTransportWrapper< folly::AsyncTransportWrapper >
 ~DecoratedAsyncTransportWrapper () override
 
- Protected Member Functions inherited from folly::AsyncTransport
 ~AsyncTransport () override=default
 
- Protected Member Functions inherited from folly::DelayedDestruction
 ~DelayedDestruction () override=default
 
 DelayedDestruction ()
 
- Protected Member Functions inherited from folly::DelayedDestructionBase
 DelayedDestructionBase ()
 
uint32_t getDestructorGuardCount () const
 
- Protected Member Functions inherited from folly::AsyncReader
virtual ~AsyncReader ()=default
 
- Protected Member Functions inherited from folly::AsyncWriter
virtual ~AsyncWriter ()=default
 
- Protected Member Functions inherited from folly::AsyncWriter::WriteCallback
virtual ~WriteCallback ()=default
 
- Protected Attributes inherited from fizz::AsyncFizzBase
folly::IOBufQueue transportReadBuf_ {folly::IOBufQueue::cacheChainLength()}
 
- Protected Attributes inherited from folly::DecoratedAsyncTransportWrapper< folly::AsyncTransportWrapper >
folly::AsyncTransportWrapper::UniquePtr transport_
 

Detailed Description

Definition at line 89 of file Mocks.h.

Constructor & Destructor Documentation

fizz::client::test::MockAsyncFizzClient::MockAsyncFizzClient ( )
inline

Definition at line 91 of file Mocks.h.

References folly::netops::close(), folly::netops::connect(), MOCK_METHOD0, and MOCK_METHOD5.

95  std::make_shared<FizzClientContext>()) {}
AsyncFizzClientT< ClientStateMachine > AsyncFizzClient
std::unique_ptr< AsyncTransportWrapper, Destructor > UniquePtr

Member Function Documentation

fizz::client::test::MockAsyncFizzClient::MOCK_METHOD0 ( close  ,
void()   
)
fizz::client::test::MockAsyncFizzClient::MOCK_METHOD0 ( closeWithReset  ,
void()   
)
fizz::client::test::MockAsyncFizzClient::MOCK_METHOD0 ( closeNow  ,
void()   
)
fizz::client::test::MockAsyncFizzClient::MOCK_METHOD5 ( connect  ,
void(HandshakeCallback *, std::shared_ptr< const CertificateVerifier >, folly::Optional< std::string >, folly::Optional< std::string >, std::chrono::milliseconds)   
)

The documentation for this class was generated from the following file: