summaryrefslogtreecommitdiffstats
path: root/sync
diff options
context:
space:
mode:
authorjochen@chromium.org <jochen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-11-13 10:25:44 +0000
committerjochen@chromium.org <jochen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-11-13 10:25:44 +0000
commit2c803849c7f516d8da0d1d0a88da53b3102ad631 (patch)
tree9971a473c62da819715fd7d033f9de1da426051a /sync
parent08039443f7dafbe39df655e45c3d116999fc0f8c (diff)
downloadchromium_src-2c803849c7f516d8da0d1d0a88da53b3102ad631.zip
chromium_src-2c803849c7f516d8da0d1d0a88da53b3102ad631.tar.gz
chromium_src-2c803849c7f516d8da0d1d0a88da53b3102ad631.tar.bz2
Revert 167337 - Move url_request_test_util into net namespace
This file contains some rather generic names like "TestDelegate". Move it to the net namespace to avoid collisions BUG=none TBR=darin@chromium.org Review URL: https://codereview.chromium.org/11369179 TBR=jochen@chromium.org Review URL: https://codereview.chromium.org/11410066 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@167356 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'sync')
-rw-r--r--sync/internal_api/http_bridge_unittest.cc14
-rw-r--r--sync/notifier/invalidator_factory_unittest.cc3
-rw-r--r--sync/notifier/non_blocking_invalidator_unittest.cc2
-rw-r--r--sync/tools/sync_client.cc6
-rw-r--r--sync/tools/sync_listen_notifications.cc6
5 files changed, 15 insertions, 16 deletions
diff --git a/sync/internal_api/http_bridge_unittest.cc b/sync/internal_api/http_bridge_unittest.cc
index 5dae475..bd2e0f8 100644
--- a/sync/internal_api/http_bridge_unittest.cc
+++ b/sync/internal_api/http_bridge_unittest.cc
@@ -48,7 +48,7 @@ class SyncHttpBridgeTest : public testing::Test {
HttpBridge* BuildBridge() {
if (!fake_default_request_context_getter_) {
fake_default_request_context_getter_ =
- new net::TestURLRequestContextGetter(io_thread_.message_loop_proxy());
+ new TestURLRequestContextGetter(io_thread_.message_loop_proxy());
fake_default_request_context_getter_->AddRef();
}
HttpBridge* bridge = new HttpBridge(
@@ -86,7 +86,7 @@ class SyncHttpBridgeTest : public testing::Test {
}
// Note this is lazy created, so don't call this before your bridge.
- net::TestURLRequestContextGetter* GetTestRequestContextGetter() {
+ TestURLRequestContextGetter* GetTestRequestContextGetter() {
return fake_default_request_context_getter_;
}
@@ -99,7 +99,7 @@ class SyncHttpBridgeTest : public testing::Test {
private:
// A make-believe "default" request context, as would be returned by
// Profile::GetDefaultRequestContext(). Created lazily by BuildBridge.
- net::TestURLRequestContextGetter* fake_default_request_context_getter_;
+ TestURLRequestContextGetter* fake_default_request_context_getter_;
HttpBridge* bridge_for_race_test_;
@@ -157,7 +157,7 @@ void SyncHttpBridgeTest::RunSyncThreadBridgeUseTest(
base::WaitableEvent* signal_when_created,
base::WaitableEvent* signal_when_released) {
scoped_refptr<net::URLRequestContextGetter> ctx_getter(
- new net::TestURLRequestContextGetter(io_thread_.message_loop_proxy()));
+ new TestURLRequestContextGetter(io_thread_.message_loop_proxy()));
{
scoped_refptr<ShuntedHttpBridge> bridge(new ShuntedHttpBridge(
ctx_getter, this, true));
@@ -187,7 +187,7 @@ TEST_F(SyncHttpBridgeTest, TestUsesSameHttpNetworkSession) {
// Test the HttpBridge without actually making any network requests.
TEST_F(SyncHttpBridgeTest, TestMakeSynchronousPostShunted) {
scoped_refptr<net::URLRequestContextGetter> ctx_getter(
- new net::TestURLRequestContextGetter(io_thread()->message_loop_proxy()));
+ new TestURLRequestContextGetter(io_thread()->message_loop_proxy()));
scoped_refptr<HttpBridge> http_bridge(new ShuntedHttpBridge(
ctx_getter, this, false));
http_bridge->SetURL("http://www.google.com", 9999);
@@ -309,7 +309,7 @@ TEST_F(SyncHttpBridgeTest, TestResponseHeader) {
TEST_F(SyncHttpBridgeTest, Abort) {
scoped_refptr<net::URLRequestContextGetter> ctx_getter(
- new net::TestURLRequestContextGetter(io_thread()->message_loop_proxy()));
+ new TestURLRequestContextGetter(io_thread()->message_loop_proxy()));
scoped_refptr<ShuntedHttpBridge> http_bridge(new ShuntedHttpBridge(
ctx_getter, this, true));
http_bridge->SetURL("http://www.google.com", 9999);
@@ -328,7 +328,7 @@ TEST_F(SyncHttpBridgeTest, Abort) {
TEST_F(SyncHttpBridgeTest, AbortLate) {
scoped_refptr<net::URLRequestContextGetter> ctx_getter(
- new net::TestURLRequestContextGetter(io_thread()->message_loop_proxy()));
+ new TestURLRequestContextGetter(io_thread()->message_loop_proxy()));
scoped_refptr<ShuntedHttpBridge> http_bridge(new ShuntedHttpBridge(
ctx_getter, this, false));
http_bridge->SetURL("http://www.google.com", 9999);
diff --git a/sync/notifier/invalidator_factory_unittest.cc b/sync/notifier/invalidator_factory_unittest.cc
index 48c4b564c..d552efd 100644
--- a/sync/notifier/invalidator_factory_unittest.cc
+++ b/sync/notifier/invalidator_factory_unittest.cc
@@ -28,8 +28,7 @@ class InvalidatorFactoryTest : public testing::Test {
virtual void SetUp() OVERRIDE {
notifier_options_.request_context_getter =
- new net::TestURLRequestContextGetter(
- message_loop_.message_loop_proxy());
+ new TestURLRequestContextGetter(message_loop_.message_loop_proxy());
}
virtual void TearDown() OVERRIDE {
diff --git a/sync/notifier/non_blocking_invalidator_unittest.cc b/sync/notifier/non_blocking_invalidator_unittest.cc
index f2a44abe..73b85bf 100644
--- a/sync/notifier/non_blocking_invalidator_unittest.cc
+++ b/sync/notifier/non_blocking_invalidator_unittest.cc
@@ -43,7 +43,7 @@ class NonBlockingInvalidatorTestDelegate {
options.message_loop_type = MessageLoop::TYPE_IO;
io_thread_.StartWithOptions(options);
request_context_getter_ =
- new net::TestURLRequestContextGetter(io_thread_.message_loop_proxy());
+ new TestURLRequestContextGetter(io_thread_.message_loop_proxy());
notifier::NotifierOptions invalidator_options;
invalidator_options.request_context_getter = request_context_getter_;
invalidator_.reset(
diff --git a/sync/tools/sync_client.cc b/sync/tools/sync_client.cc
index f49e59e..78db3b4 100644
--- a/sync/tools/sync_client.cc
+++ b/sync/tools/sync_client.cc
@@ -101,7 +101,7 @@ class NullInvalidationStateTracker
};
// Needed to use a real host resolver.
-class MyTestURLRequestContext : public net::TestURLRequestContext {
+class MyTestURLRequestContext : public TestURLRequestContext {
public:
MyTestURLRequestContext() : TestURLRequestContext(true) {
context_storage_.set_host_resolver(
@@ -114,13 +114,13 @@ class MyTestURLRequestContext : public net::TestURLRequestContext {
virtual ~MyTestURLRequestContext() {}
};
-class MyTestURLRequestContextGetter : public net::TestURLRequestContextGetter {
+class MyTestURLRequestContextGetter : public TestURLRequestContextGetter {
public:
explicit MyTestURLRequestContextGetter(
const scoped_refptr<base::MessageLoopProxy>& io_message_loop_proxy)
: TestURLRequestContextGetter(io_message_loop_proxy) {}
- virtual net::TestURLRequestContext* GetURLRequestContext() OVERRIDE {
+ virtual TestURLRequestContext* GetURLRequestContext() OVERRIDE {
// Construct |context_| lazily so it gets constructed on the right
// thread (the IO thread).
if (!context_.get())
diff --git a/sync/tools/sync_listen_notifications.cc b/sync/tools/sync_listen_notifications.cc
index bc90088..d8cc213 100644
--- a/sync/tools/sync_listen_notifications.cc
+++ b/sync/tools/sync_listen_notifications.cc
@@ -114,7 +114,7 @@ class NullInvalidationStateTracker
};
// Needed to use a real host resolver.
-class MyTestURLRequestContext : public net::TestURLRequestContext {
+class MyTestURLRequestContext : public TestURLRequestContext {
public:
MyTestURLRequestContext() : TestURLRequestContext(true) {
context_storage_.set_host_resolver(
@@ -127,13 +127,13 @@ class MyTestURLRequestContext : public net::TestURLRequestContext {
virtual ~MyTestURLRequestContext() {}
};
-class MyTestURLRequestContextGetter : public net::TestURLRequestContextGetter {
+class MyTestURLRequestContextGetter : public TestURLRequestContextGetter {
public:
explicit MyTestURLRequestContextGetter(
const scoped_refptr<base::MessageLoopProxy>& io_message_loop_proxy)
: TestURLRequestContextGetter(io_message_loop_proxy) {}
- virtual net::TestURLRequestContext* GetURLRequestContext() OVERRIDE {
+ virtual TestURLRequestContext* GetURLRequestContext() OVERRIDE {
// Construct |context_| lazily so it gets constructed on the right
// thread (the IO thread).
if (!context_.get())