summaryrefslogtreecommitdiffstats
path: root/net/ssl
diff options
context:
space:
mode:
authorxhwang@chromium.org <xhwang@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-05-23 20:51:34 +0000
committerxhwang@chromium.org <xhwang@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-05-23 20:51:34 +0000
commit2da659e6279cf515940eb8a091e09e27281a97d6 (patch)
treea34e2eeea8194a16603e24149ae634cb54ddab62 /net/ssl
parent954f56f3aceed29573f841648168b91c1fd43074 (diff)
downloadchromium_src-2da659e6279cf515940eb8a091e09e27281a97d6.zip
chromium_src-2da659e6279cf515940eb8a091e09e27281a97d6.tar.gz
chromium_src-2da659e6279cf515940eb8a091e09e27281a97d6.tar.bz2
net: Use base::MessageLoop.
BUG=236029 R=agl@chromium.org Review URL: https://chromiumcodereview.appspot.com/14021017 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@201882 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/ssl')
-rw-r--r--net/ssl/default_server_bound_cert_store_unittest.cc22
-rw-r--r--net/ssl/server_bound_cert_service_unittest.cc8
2 files changed, 15 insertions, 15 deletions
diff --git a/net/ssl/default_server_bound_cert_store_unittest.cc b/net/ssl/default_server_bound_cert_store_unittest.cc
index d52d286..1ab5e54 100644
--- a/net/ssl/default_server_bound_cert_store_unittest.cc
+++ b/net/ssl/default_server_bound_cert_store_unittest.cc
@@ -101,7 +101,7 @@ void MockPersistentStore::Load(const LoadedCallback& loaded_callback) {
new DefaultServerBoundCertStore::ServerBoundCert(it->second));
}
- MessageLoop::current()->PostTask(
+ base::MessageLoop::current()->PostTask(
FROM_HERE, base::Bind(loaded_callback, base::Passed(&certs)));
}
@@ -150,7 +150,7 @@ TEST(DefaultServerBoundCertStoreTest, TestLoading) {
base::Time(),
"e", "f");
// Wait for load & queued set task.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
EXPECT_EQ(2, store.GetCertCount());
store.SetServerBoundCert(
"twitter.com",
@@ -219,7 +219,7 @@ TEST(DefaultServerBoundCertStoreTest, TestDuplicateCerts) {
"c", "d");
// Wait for load & queued set tasks.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
EXPECT_EQ(1, store.GetCertCount());
EXPECT_TRUE(store.GetServerBoundCert("verisign.com",
&type,
@@ -254,7 +254,7 @@ TEST(DefaultServerBoundCertStoreTest, TestAsyncGet) {
base::Bind(&AsyncGetCertHelper::Callback, base::Unretained(&helper))));
// Wait for load & queued get tasks.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
EXPECT_EQ(1, store.GetCertCount());
EXPECT_EQ("not set", cert);
EXPECT_TRUE(helper.called_);
@@ -288,7 +288,7 @@ TEST(DefaultServerBoundCertStoreTest, TestDeleteAll) {
base::Time(),
"e", "f");
// Wait for load & queued set tasks.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
EXPECT_EQ(3, store.GetCertCount());
int delete_finished = 0;
@@ -323,7 +323,7 @@ TEST(DefaultServerBoundCertStoreTest, TestAsyncGetAndDeleteAll) {
// Tasks have not run yet.
EXPECT_EQ(0u, pre_certs.size());
// Wait for load & queued tasks.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
EXPECT_EQ(0, store.GetCertCount());
EXPECT_EQ(2u, pre_certs.size());
EXPECT_EQ(0u, post_certs.size());
@@ -344,7 +344,7 @@ TEST(DefaultServerBoundCertStoreTest, TestDelete) {
base::Time(),
"a", "b");
// Wait for load & queued set task.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
store.SetServerBoundCert(
"google.com",
@@ -424,7 +424,7 @@ TEST(DefaultServerBoundCertStoreTest, TestAsyncDelete) {
EXPECT_FALSE(a_helper.called_);
EXPECT_FALSE(b_helper.called_);
// Wait for load & queued tasks.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
EXPECT_EQ(1, delete_finished);
EXPECT_EQ(1, store.GetCertCount());
EXPECT_EQ("not set", cert);
@@ -472,7 +472,7 @@ TEST(DefaultServerBoundCertStoreTest, TestGetAll) {
base::Time(),
"g", "h");
// Wait for load & queued set tasks.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
EXPECT_EQ(4, store.GetCertCount());
ServerBoundCertStore::ServerBoundCertList certs;
@@ -497,7 +497,7 @@ TEST(DefaultServerBoundCertStoreTest, TestInitializeFrom) {
base::Time(),
"c", "d");
// Wait for load & queued set tasks.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
EXPECT_EQ(2, store.GetCertCount());
ServerBoundCertStore::ServerBoundCertList source_certs;
@@ -567,7 +567,7 @@ TEST(DefaultServerBoundCertStoreTest, TestAsyncInitializeFrom) {
store.InitializeFrom(source_certs);
EXPECT_EQ(0, store.GetCertCount());
// Wait for load & queued tasks.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
EXPECT_EQ(3, store.GetCertCount());
ServerBoundCertStore::ServerBoundCertList certs;
diff --git a/net/ssl/server_bound_cert_service_unittest.cc b/net/ssl/server_bound_cert_service_unittest.cc
index d913381..51c74bf 100644
--- a/net/ssl/server_bound_cert_service_unittest.cc
+++ b/net/ssl/server_bound_cert_service_unittest.cc
@@ -352,7 +352,7 @@ TEST_F(ServerBoundCertServiceTest, CancelRequest) {
sequenced_worker_pool_->FlushForTesting();
// Wait for reply from ServerBoundCertServiceWorker to be posted back to the
// ServerBoundCertService.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
// Even though the original request was cancelled, the service will still
// store the result, it just doesn't call the callback.
@@ -385,7 +385,7 @@ TEST_F(ServerBoundCertServiceTest, CancelRequestByHandleDestruction) {
sequenced_worker_pool_->FlushForTesting();
// Wait for reply from ServerBoundCertServiceWorker to be posted back to the
// ServerBoundCertService.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
// Even though the original request was cancelled, the service will still
// store the result, it just doesn't call the callback.
@@ -420,7 +420,7 @@ TEST_F(ServerBoundCertServiceTest, DestructionWithPendingRequest) {
// ServerBoundCertServiceWorker should not post anything back to the
// non-existant ServerBoundCertService, but run the loop just to be sure it
// doesn't.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
// If we got here without crashing or a valgrind error, it worked.
}
@@ -434,7 +434,7 @@ TEST_F(ServerBoundCertServiceTest, RequestAfterPoolShutdown) {
sequenced_worker_pool_ = NULL;
// Ensure any shutdown code is processed.
- MessageLoop::current()->RunUntilIdle();
+ base::MessageLoop::current()->RunUntilIdle();
// Make a request that will force synchronous completion.
std::string host("encrypted.google.com");