| Index: content/browser/appcache/appcache_url_request_job_unittest.cc
|
| diff --git a/content/browser/appcache/appcache_url_request_job_unittest.cc b/content/browser/appcache/appcache_url_request_job_unittest.cc
|
| index f29607db47107c979483d21606906cefccae4f40..eb2ea078b9db57cb4ac0f864e227a209fab6c2c2 100644
|
| --- a/content/browser/appcache/appcache_url_request_job_unittest.cc
|
| +++ b/content/browser/appcache/appcache_url_request_job_unittest.cc
|
| @@ -466,11 +466,11 @@ class AppCacheURLRequestJobTest : public testing::Test {
|
| std::unique_ptr<AppCacheURLRequestJob> job(
|
| new AppCacheURLRequestJob(request_.get(), nullptr, storage, nullptr,
|
| false, base::Bind(&ExpectNotRestarted)));
|
| - EXPECT_TRUE(job->is_waiting());
|
| - EXPECT_FALSE(job->is_delivering_appcache_response());
|
| - EXPECT_FALSE(job->is_delivering_network_response());
|
| - EXPECT_FALSE(job->is_delivering_error_response());
|
| - EXPECT_FALSE(job->has_been_started());
|
| + EXPECT_TRUE(job->IsWaiting());
|
| + EXPECT_FALSE(job->IsDeliveringAppCacheResponse());
|
| + EXPECT_FALSE(job->IsDeliveringNetworkResponse());
|
| + EXPECT_FALSE(job->IsDeliveringErrorResponse());
|
| + EXPECT_FALSE(job->IsStarted());
|
| EXPECT_FALSE(job->has_been_killed());
|
| EXPECT_EQ(GURL(), job->manifest_url());
|
| EXPECT_EQ(kAppCacheNoCacheId, job->cache_id());
|
| @@ -492,15 +492,15 @@ class AppCacheURLRequestJobTest : public testing::Test {
|
| new AppCacheURLRequestJob(request.get(), nullptr, storage, nullptr,
|
| false, base::Bind(&ExpectNotRestarted)));
|
| job->DeliverErrorResponse();
|
| - EXPECT_TRUE(job->is_delivering_error_response());
|
| - EXPECT_FALSE(job->has_been_started());
|
| + EXPECT_TRUE(job->IsDeliveringErrorResponse());
|
| + EXPECT_FALSE(job->IsStarted());
|
|
|
| job.reset(new AppCacheURLRequestJob(request.get(), nullptr, storage,
|
| nullptr, false,
|
| base::Bind(&ExpectNotRestarted)));
|
| job->DeliverNetworkResponse();
|
| - EXPECT_TRUE(job->is_delivering_network_response());
|
| - EXPECT_FALSE(job->has_been_started());
|
| + EXPECT_TRUE(job->IsDeliveringNetworkResponse());
|
| + EXPECT_FALSE(job->IsStarted());
|
|
|
| job.reset(new AppCacheURLRequestJob(request.get(), nullptr, storage,
|
| nullptr, false,
|
| @@ -509,9 +509,9 @@ class AppCacheURLRequestJobTest : public testing::Test {
|
| const int64_t kCacheId(1);
|
| const AppCacheEntry kEntry(AppCacheEntry::EXPLICIT, 1);
|
| job->DeliverAppCachedResponse(kManifestUrl, kCacheId, kEntry, false);
|
| - EXPECT_FALSE(job->is_waiting());
|
| - EXPECT_TRUE(job->is_delivering_appcache_response());
|
| - EXPECT_FALSE(job->has_been_started());
|
| + EXPECT_FALSE(job->IsWaiting());
|
| + EXPECT_TRUE(job->IsDeliveringAppCacheResponse());
|
| + EXPECT_FALSE(job->IsStarted());
|
| EXPECT_EQ(kManifestUrl, job->manifest_url());
|
| EXPECT_EQ(kCacheId, job->cache_id());
|
| EXPECT_EQ(kEntry.types(), job->entry().types());
|
| @@ -539,8 +539,8 @@ class AppCacheURLRequestJobTest : public testing::Test {
|
| request_.get(), nullptr, storage, nullptr, false,
|
| base::Bind(&SetIfCalled, &restart_callback_invoked_)));
|
| mock_job->DeliverNetworkResponse();
|
| - EXPECT_TRUE(mock_job->is_delivering_network_response());
|
| - EXPECT_FALSE(mock_job->has_been_started());
|
| + EXPECT_TRUE(mock_job->IsDeliveringNetworkResponse());
|
| + EXPECT_FALSE(mock_job->IsStarted());
|
| job_factory_->SetJob(std::move(mock_job));
|
|
|
| // Start the request.
|
| @@ -577,8 +577,8 @@ class AppCacheURLRequestJobTest : public testing::Test {
|
| new AppCacheURLRequestJob(request_.get(), nullptr, storage, nullptr,
|
| false, base::Bind(&ExpectNotRestarted)));
|
| mock_job->DeliverErrorResponse();
|
| - EXPECT_TRUE(mock_job->is_delivering_error_response());
|
| - EXPECT_FALSE(mock_job->has_been_started());
|
| + EXPECT_TRUE(mock_job->IsDeliveringErrorResponse());
|
| + EXPECT_FALSE(mock_job->IsStarted());
|
| job_factory_->SetJob(std::move(mock_job));
|
|
|
| // Start the request.
|
| @@ -633,24 +633,24 @@ class AppCacheURLRequestJobTest : public testing::Test {
|
| job->DeliverAppCachedResponse(
|
| GURL(), 111,
|
| AppCacheEntry(AppCacheEntry::EXPLICIT, written_response_id_), false);
|
| - EXPECT_TRUE(job->is_delivering_appcache_response());
|
| + EXPECT_TRUE(job->IsDeliveringAppCacheResponse());
|
| }
|
|
|
| // Start the request.
|
| - EXPECT_FALSE(job->has_been_started());
|
| - base::WeakPtr<AppCacheURLRequestJob> weak_job = job->GetWeakPtr();
|
| + EXPECT_FALSE(job->IsStarted());
|
| + base::WeakPtr<AppCacheJob> weak_job = job->GetWeakPtr();
|
| job_factory_->SetJob(std::move(job));
|
| request_->Start();
|
| EXPECT_FALSE(job_factory_->has_job());
|
| ASSERT_TRUE(weak_job);
|
| - EXPECT_TRUE(weak_job->has_been_started());
|
| + EXPECT_TRUE(weak_job->IsStarted());
|
|
|
| if (!start_after_delivery_orders) {
|
| weak_job->DeliverAppCachedResponse(
|
| GURL(), 111,
|
| AppCacheEntry(AppCacheEntry::EXPLICIT, written_response_id_), false);
|
| ASSERT_TRUE(weak_job);
|
| - EXPECT_TRUE(weak_job->is_delivering_appcache_response());
|
| + EXPECT_TRUE(weak_job->IsDeliveringAppCacheResponse());
|
| }
|
|
|
| // Completion is async.
|
| @@ -751,10 +751,10 @@ class AppCacheURLRequestJobTest : public testing::Test {
|
| job->DeliverAppCachedResponse(
|
| GURL(), 111,
|
| AppCacheEntry(AppCacheEntry::EXPLICIT, written_response_id_), false);
|
| - EXPECT_TRUE(job->is_delivering_appcache_response());
|
| + EXPECT_TRUE(job->IsDeliveringAppCacheResponse());
|
|
|
| // Start the request.
|
| - EXPECT_FALSE(job->has_been_started());
|
| + EXPECT_FALSE(job->IsStarted());
|
| job_factory_->SetJob(std::move(job));
|
| request_->Start();
|
| EXPECT_FALSE(job_factory_->has_job());
|
|
|