#include "quiche/quic/tools/quic_simple_server_session.h"
#include <algorithm>
#include <memory>
#include <utility>
#include "absl/strings/str_cat.h"
#include "quiche/quic/core/crypto/null_encrypter.h"
#include "quiche/quic/core/crypto/quic_crypto_server_config.h"
#include "quiche/quic/core/crypto/quic_random.h"
#include "quiche/quic/core/http/http_encoder.h"
#include "quiche/quic/core/proto/cached_network_parameters_proto.h"
#include "quiche/quic/core/quic_connection.h"
#include "quiche/quic/core/quic_crypto_server_stream.h"
#include "quiche/quic/core/quic_utils.h"
#include "quiche/quic/core/quic_versions.h"
#include "quiche/quic/core/tls_server_handshaker.h"
#include "quiche/quic/platform/api/quic_expect_bug.h"
#include "quiche/quic/platform/api/quic_flags.h"
#include "quiche/quic/platform/api/quic_socket_address.h"
#include "quiche/quic/platform/api/quic_test.h"
#include "quiche/quic/test_tools/crypto_test_utils.h"
#include "quiche/quic/test_tools/mock_quic_session_visitor.h"
#include "quiche/quic/test_tools/quic_config_peer.h"
#include "quiche/quic/test_tools/quic_connection_peer.h"
#include "quiche/quic/test_tools/quic_sent_packet_manager_peer.h"
#include "quiche/quic/test_tools/quic_session_peer.h"
#include "quiche/quic/test_tools/quic_spdy_session_peer.h"
#include "quiche/quic/test_tools/quic_stream_peer.h"
#include "quiche/quic/test_tools/quic_sustained_bandwidth_recorder_peer.h"
#include "quiche/quic/test_tools/quic_test_utils.h"
#include "quiche/quic/tools/quic_backend_response.h"
#include "quiche/quic/tools/quic_memory_cache_backend.h"
#include "quiche/quic/tools/quic_simple_server_stream.h"
_;
AtLeast;
InSequence;
Invoke;
Return;
StrictMock;
namespace quic {
namespace test {
namespace {
const char* const kStreamData = …;
}
class QuicSimpleServerSessionPeer { … };
namespace {
const size_t kMaxStreamsForTest = …;
class MockQuicCryptoServerStream : public QuicCryptoServerStream { … };
class MockTlsServerHandshaker : public TlsServerHandshaker { … };
class MockQuicConnectionWithSendStreamData : public MockQuicConnection { … };
class MockQuicSimpleServerSession : public QuicSimpleServerSession { … };
class QuicSimpleServerSessionTest
: public QuicTestWithParam<ParsedQuicVersion> { … };
INSTANTIATE_TEST_SUITE_P(…);
TEST_P(QuicSimpleServerSessionTest, CloseStreamDueToReset) { … }
TEST_P(QuicSimpleServerSessionTest, NeverOpenStreamDueToReset) { … }
TEST_P(QuicSimpleServerSessionTest, AcceptClosedStream) { … }
TEST_P(QuicSimpleServerSessionTest, CreateIncomingStreamDisconnected) { … }
TEST_P(QuicSimpleServerSessionTest, CreateIncomingStream) { … }
TEST_P(QuicSimpleServerSessionTest, CreateOutgoingDynamicStreamDisconnected) { … }
TEST_P(QuicSimpleServerSessionTest, CreateOutgoingDynamicStreamUnencrypted) { … }
TEST_P(QuicSimpleServerSessionTest, GetEvenIncomingError) { … }
}
}
}