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

Unified Diff: webkit/browser/appcache/appcache_url_request_job_unittest.cc

Issue 51953002: [Net] Add a priority parameter to URLRequest's constructor (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address comments Created 7 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webkit/browser/appcache/appcache_update_job.cc ('k') | webkit/browser/blob/blob_url_request_job_factory.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/browser/appcache/appcache_url_request_job_unittest.cc
diff --git a/webkit/browser/appcache/appcache_url_request_job_unittest.cc b/webkit/browser/appcache/appcache_url_request_job_unittest.cc
index 95ad3bb8ae22689919fb2ccc7f79611dcc3235d0..3f9675a96ca6ba42e4aa57de9f5e36114a477c04 100644
--- a/webkit/browser/appcache/appcache_url_request_job_unittest.cc
+++ b/webkit/browser/appcache/appcache_url_request_job_unittest.cc
@@ -14,6 +14,7 @@
#include "base/threading/thread.h"
#include "net/base/io_buffer.h"
#include "net/base/net_errors.h"
+#include "net/base/request_priority.h"
#include "net/http/http_response_headers.h"
#include "net/url_request/url_request.h"
#include "net/url_request/url_request_context.h"
@@ -376,7 +377,8 @@ class AppCacheURLRequestJobTest : public testing::Test {
// Basic -------------------------------------------------------------------
void Basic() {
AppCacheStorage* storage = service_->storage();
- net::URLRequest request(GURL("http://blah/"), NULL, &empty_context_);
+ net::URLRequest request(
+ GURL("http://blah/"), net::DEFAULT_PRIORITY, NULL, &empty_context_);
scoped_refptr<AppCacheURLRequestJob> job;
// Create an instance and see that it looks as expected.
@@ -399,7 +401,8 @@ class AppCacheURLRequestJobTest : public testing::Test {
// DeliveryOrders -----------------------------------------------------
void DeliveryOrders() {
AppCacheStorage* storage = service_->storage();
- net::URLRequest request(GURL("http://blah/"), NULL, &empty_context_);
+ net::URLRequest request(
+ GURL("http://blah/"), net::DEFAULT_PRIORITY, NULL, &empty_context_);
scoped_refptr<AppCacheURLRequestJob> job;
// Create an instance, give it a delivery order and see that
@@ -443,8 +446,9 @@ class AppCacheURLRequestJobTest : public testing::Test {
base::Unretained(this)));
AppCacheStorage* storage = service_->storage();
- request_.reset(empty_context_.CreateRequest(
- GURL("http://blah/"), url_request_delegate_.get()));
+ request_ = empty_context_.CreateRequest(GURL("http://blah/"),
+ net::DEFAULT_PRIORITY,
+ url_request_delegate_.get());
// Setup to create an AppCacheURLRequestJob with orders to deliver
// a network response.
@@ -477,8 +481,9 @@ class AppCacheURLRequestJobTest : public testing::Test {
base::Unretained(this)));
AppCacheStorage* storage = service_->storage();
- request_.reset(empty_context_.CreateRequest(GURL(
- "http://blah/"), url_request_delegate_.get()));
+ request_ = empty_context_.CreateRequest(GURL("http://blah/"),
+ net::DEFAULT_PRIORITY,
+ url_request_delegate_.get());
// Setup to create an AppCacheURLRequestJob with orders to deliver
// a network response.
@@ -526,8 +531,9 @@ class AppCacheURLRequestJobTest : public testing::Test {
void RequestAppCachedResource(bool start_after_delivery_orders) {
AppCacheStorage* storage = service_->storage();
- request_.reset(empty_context_.CreateRequest(
- GURL("http://blah/"), url_request_delegate_.get()));
+ request_ = empty_context_.CreateRequest(GURL("http://blah/"),
+ net::DEFAULT_PRIORITY,
+ url_request_delegate_.get());
// Setup to create an AppCacheURLRequestJob with orders to deliver
// a network response.
@@ -639,8 +645,9 @@ class AppCacheURLRequestJobTest : public testing::Test {
void MakeRangeRequest() {
AppCacheStorage* storage = service_->storage();
- request_.reset(empty_context_.CreateRequest(
- GURL("http://blah/"), url_request_delegate_.get()));
+ request_ = empty_context_.CreateRequest(GURL("http://blah/"),
+ net::DEFAULT_PRIORITY,
+ url_request_delegate_.get());
// Request a range, the 3 middle chars out of 'Hello'
net::HttpRequestHeaders extra_headers;
« no previous file with comments | « webkit/browser/appcache/appcache_update_job.cc ('k') | webkit/browser/blob/blob_url_request_job_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698