#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "net/spdy/spdy_http_stream.h"
#include <stdint.h>
#include <set>
#include <string>
#include "base/functional/bind.h"
#include "base/memory/raw_ptr.h"
#include "base/run_loop.h"
#include "base/task/single_thread_task_runner.h"
#include "base/test/scoped_feature_list.h"
#include "crypto/ec_private_key.h"
#include "crypto/ec_signature_creator.h"
#include "crypto/signature_creator.h"
#include "net/base/chunked_upload_data_stream.h"
#include "net/base/features.h"
#include "net/base/load_timing_info.h"
#include "net/base/load_timing_info_test_util.h"
#include "net/base/session_usage.h"
#include "net/base/test_completion_callback.h"
#include "net/cert/asn1_util.h"
#include "net/dns/public/secure_dns_policy.h"
#include "net/http/http_request_info.h"
#include "net/http/http_response_headers.h"
#include "net/http/http_response_info.h"
#include "net/log/net_log_with_source.h"
#include "net/quic/quic_http_utils.h"
#include "net/socket/socket_tag.h"
#include "net/socket/socket_test_util.h"
#include "net/spdy/spdy_http_utils.h"
#include "net/spdy/spdy_test_util_common.h"
#include "net/test/cert_test_util.h"
#include "net/test/gtest_util.h"
#include "net/test/test_data_directory.h"
#include "net/test/test_with_task_environment.h"
#include "net/third_party/quiche/src/quiche/common/http/http_header_block.h"
#include "net/traffic_annotation/network_traffic_annotation_test_helper.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace net::test {
namespace {
void TestLoadTimingReused(const HttpStream& stream) { … }
void TestLoadTimingNotReused(const HttpStream& stream) { … }
class ReadErrorUploadDataStream : public UploadDataStream { … };
class CancelStreamCallback : public TestCompletionCallbackBase { … };
}
class SpdyHttpStreamTest : public testing::TestWithParam<bool>,
public WithTaskEnvironment { … };
INSTANTIATE_TEST_SUITE_P(…);
TEST_P(SpdyHttpStreamTest, SendRequest) { … }
TEST_P(SpdyHttpStreamTest, RequestInfoDestroyedBeforeRead) { … }
TEST_P(SpdyHttpStreamTest, LoadTimingTwoRequests) { … }
TEST_P(SpdyHttpStreamTest, SendChunkedPost) { … }
TEST_P(SpdyHttpStreamTest, SendChunkedPostLastEmpty) { … }
TEST_P(SpdyHttpStreamTest, ConnectionClosedDuringChunkedPost) { … }
TEST_P(SpdyHttpStreamTest, DelayedSendChunkedPost) { … }
TEST_P(SpdyHttpStreamTest, DelayedSendChunkedPostWithEmptyFinalDataFrame) { … }
TEST_P(SpdyHttpStreamTest, ChunkedPostWithEmptyPayload) { … }
TEST_P(SpdyHttpStreamTest, SpdyURLTest) { … }
TEST_P(SpdyHttpStreamTest, DelayedSendChunkedPostWithWindowUpdate) { … }
TEST_P(SpdyHttpStreamTest, DataReadErrorSynchronous) { … }
TEST_P(SpdyHttpStreamTest, DataReadErrorAsynchronous) { … }
TEST_P(SpdyHttpStreamTest, RequestCallbackCancelsStream) { … }
TEST_P(SpdyHttpStreamTest, DownloadWithEmptyDataFrame) { … }
}