#include "components/sync/engine/net/http_bridge.h"
#include <stddef.h>
#include <utility>
#include "base/functional/bind.h"
#include "base/memory/raw_ptr.h"
#include "base/memory/scoped_refptr.h"
#include "base/message_loop/message_pump_type.h"
#include "base/strings/stringprintf.h"
#include "base/task/single_thread_task_runner.h"
#include "base/test/bind.h"
#include "base/test/task_environment.h"
#include "base/threading/thread.h"
#include "build/build_config.h"
#include "components/variations/scoped_variations_ids_provider.h"
#include "net/http/http_request_headers.h"
#include "net/http/http_status_code.h"
#include "net/test/embedded_test_server/embedded_test_server.h"
#include "services/network/test/test_shared_url_loader_factory.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/zlib/google/compression_utils.h"
namespace syncer {
namespace {
HasSubstr;
const base::FilePath::CharType kDocRoot[] = …);
}
const char kUserAgent[] = …;
#if BUILDFLAG(IS_ANDROID)
#define MAYBE_SyncHttpBridgeTest …
#else
#define MAYBE_SyncHttpBridgeTest …
#endif
class MAYBE_SyncHttpBridgeTest : public testing::Test { … };
class ShuntedHttpBridge : public HttpBridge { … };
void MAYBE_SyncHttpBridgeTest::RunSyncThreadBridgeUseTest(
base::WaitableEvent* signal_when_created,
base::WaitableEvent* signal_when_released) { … }
TEST_F(MAYBE_SyncHttpBridgeTest, TestMakeSynchronousPostShunted) { … }
TEST_F(MAYBE_SyncHttpBridgeTest, CompressedRequestPayloadCheck) { … }
TEST_F(MAYBE_SyncHttpBridgeTest, CompressedRequestHeaderCheck) { … }
TEST_F(MAYBE_SyncHttpBridgeTest, TestExtraRequestHeaders) { … }
TEST_F(MAYBE_SyncHttpBridgeTest, TestResponseHeader) { … }
TEST_F(MAYBE_SyncHttpBridgeTest, HttpErrors) { … }
TEST_F(MAYBE_SyncHttpBridgeTest, NetErrorUnreached) { … }
TEST_F(MAYBE_SyncHttpBridgeTest, Abort) { … }
TEST_F(MAYBE_SyncHttpBridgeTest, AbortLate) { … }
TEST_F(MAYBE_SyncHttpBridgeTest, AbortAndReleaseBeforeFetchComplete) { … }
}