| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 <ostream> | 5 #include <ostream> |
| 6 #include <vector> | 6 #include <vector> |
| 7 | 7 |
| 8 #include "base/bind.h" | 8 #include "base/bind.h" |
| 9 #include "base/message_loop.h" | 9 #include "base/message_loop.h" |
| 10 #include "base/string_split.h" | 10 #include "base/string_split.h" |
| (...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 268 FailedRequestParams( | 268 FailedRequestParams( |
| 269 DM_STATUS_TEMPORARY_UNAVAILABLE, | 269 DM_STATUS_TEMPORARY_UNAVAILABLE, |
| 270 net::URLRequestStatus::SUCCESS, | 270 net::URLRequestStatus::SUCCESS, |
| 271 404, | 271 404, |
| 272 PROTO_STRING(kResponseEmpty)), | 272 PROTO_STRING(kResponseEmpty)), |
| 273 FailedRequestParams( | 273 FailedRequestParams( |
| 274 DM_STATUS_SERVICE_ACTIVATION_PENDING, | 274 DM_STATUS_SERVICE_ACTIVATION_PENDING, |
| 275 net::URLRequestStatus::SUCCESS, | 275 net::URLRequestStatus::SUCCESS, |
| 276 412, | 276 412, |
| 277 PROTO_STRING(kResponseEmpty)), | 277 PROTO_STRING(kResponseEmpty)), |
| 278 FailedRequestParams( |
| 279 DM_STATUS_MISSING_LICENSES, |
| 280 net::URLRequestStatus::SUCCESS, |
| 281 402, |
| 282 PROTO_STRING(kResponseEmpty)), |
| 278 // TODO(pastarmovj): Remove once DM server is deployed. | 283 // TODO(pastarmovj): Remove once DM server is deployed. |
| 279 FailedRequestParams( | 284 FailedRequestParams( |
| 280 DM_STATUS_SERVICE_ACTIVATION_PENDING, | 285 DM_STATUS_SERVICE_ACTIVATION_PENDING, |
| 281 net::URLRequestStatus::SUCCESS, | 286 net::URLRequestStatus::SUCCESS, |
| 282 491, | 287 491, |
| 283 PROTO_STRING(kResponseEmpty)))); | 288 PROTO_STRING(kResponseEmpty)))); |
| 284 | 289 |
| 285 // Simple query parameter parser for testing. | 290 // Simple query parameter parser for testing. |
| 286 class QueryParams { | 291 class QueryParams { |
| 287 public: | 292 public: |
| (...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 546 | 551 |
| 547 // Verify that a new URLFetcher was started that bypasses the proxy. | 552 // Verify that a new URLFetcher was started that bypasses the proxy. |
| 548 fetcher = factory_.GetFetcherByID(0); | 553 fetcher = factory_.GetFetcherByID(0); |
| 549 ASSERT_TRUE(fetcher); | 554 ASSERT_TRUE(fetcher); |
| 550 EXPECT_TRUE((fetcher->GetLoadFlags() & net::LOAD_BYPASS_PROXY) != 0); | 555 EXPECT_TRUE((fetcher->GetLoadFlags() & net::LOAD_BYPASS_PROXY) != 0); |
| 551 EXPECT_EQ(original_url, fetcher->GetOriginalURL()); | 556 EXPECT_EQ(original_url, fetcher->GetOriginalURL()); |
| 552 EXPECT_EQ(upload_data, fetcher->upload_data()); | 557 EXPECT_EQ(upload_data, fetcher->upload_data()); |
| 553 } | 558 } |
| 554 | 559 |
| 555 } // namespace policy | 560 } // namespace policy |
| OLD | NEW |