Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(17)

Side by Side Diff: content/browser/cache_storage/cache_storage_manager_unittest.cc

Issue 1750333002: Reland of Pipe response_time from FetchManager to CacheStorage and ServiceWorkerURLRequestJob. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/cache_storage/cache_storage_manager.h" 5 #include "content/browser/cache_storage/cache_storage_manager.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after
233 233
234 scoped_ptr<storage::BlobDataBuilder> blob_data( 234 scoped_ptr<storage::BlobDataBuilder> blob_data(
235 new storage::BlobDataBuilder(base::GenerateGUID())); 235 new storage::BlobDataBuilder(base::GenerateGUID()));
236 blob_data->AppendData(url.spec()); 236 blob_data->AppendData(url.spec());
237 237
238 scoped_ptr<storage::BlobDataHandle> blob_handle = 238 scoped_ptr<storage::BlobDataHandle> blob_handle =
239 blob_storage_context_->AddFinishedBlob(blob_data.get()); 239 blob_storage_context_->AddFinishedBlob(blob_data.get());
240 ServiceWorkerResponse response( 240 ServiceWorkerResponse response(
241 url, 200, "OK", blink::WebServiceWorkerResponseTypeDefault, 241 url, 200, "OK", blink::WebServiceWorkerResponseTypeDefault,
242 ServiceWorkerHeaderMap(), blob_handle->uuid(), url.spec().size(), 242 ServiceWorkerHeaderMap(), blob_handle->uuid(), url.spec().size(),
243 GURL(), blink::WebServiceWorkerResponseErrorUnknown); 243 GURL(), blink::WebServiceWorkerResponseErrorUnknown, base::Time());
244 244
245 CacheStorageBatchOperation operation; 245 CacheStorageBatchOperation operation;
246 operation.operation_type = CACHE_STORAGE_CACHE_OPERATION_TYPE_PUT; 246 operation.operation_type = CACHE_STORAGE_CACHE_OPERATION_TYPE_PUT;
247 operation.request = request; 247 operation.request = request;
248 operation.response = response; 248 operation.response = response;
249 249
250 base::RunLoop loop; 250 base::RunLoop loop;
251 cache->BatchOperation( 251 cache->BatchOperation(
252 std::vector<CacheStorageBatchOperation>(1, operation), 252 std::vector<CacheStorageBatchOperation>(1, operation),
253 base::Bind(&CacheStorageManagerTest::CachePutCallback, 253 base::Bind(&CacheStorageManagerTest::CachePutCallback,
(...skipping 783 matching lines...) Expand 10 before | Expand all | Expand 10 after
1037 1037
1038 INSTANTIATE_TEST_CASE_P(CacheStorageManagerTests, 1038 INSTANTIATE_TEST_CASE_P(CacheStorageManagerTests,
1039 CacheStorageManagerTestP, 1039 CacheStorageManagerTestP,
1040 ::testing::Values(false, true)); 1040 ::testing::Values(false, true));
1041 1041
1042 INSTANTIATE_TEST_CASE_P(CacheStorageQuotaClientTests, 1042 INSTANTIATE_TEST_CASE_P(CacheStorageQuotaClientTests,
1043 CacheStorageQuotaClientTestP, 1043 CacheStorageQuotaClientTestP,
1044 ::testing::Values(false, true)); 1044 ::testing::Values(false, true));
1045 1045
1046 } // namespace content 1046 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698