| OLD | NEW |
| 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 "components/data_reduction_proxy/core/browser/data_reduction_proxy_requ
est_options.h" | 5 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_requ
est_options.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 *expected_header = base::JoinString(expected_options, ", "); | 137 *expected_header = base::JoinString(expected_options, ", "); |
| 138 } | 138 } |
| 139 | 139 |
| 140 } // namespace | 140 } // namespace |
| 141 | 141 |
| 142 class DataReductionProxyRequestOptionsTest : public testing::Test { | 142 class DataReductionProxyRequestOptionsTest : public testing::Test { |
| 143 public: | 143 public: |
| 144 DataReductionProxyRequestOptionsTest() { | 144 DataReductionProxyRequestOptionsTest() { |
| 145 test_context_ = | 145 test_context_ = |
| 146 DataReductionProxyTestContext::Builder() | 146 DataReductionProxyTestContext::Builder() |
| 147 .WithParamsFlags(0) | |
| 148 .WithParamsDefinitions(TestDataReductionProxyParams::HAS_EVERYTHING) | |
| 149 .Build(); | 147 .Build(); |
| 150 } | 148 } |
| 151 | 149 |
| 152 void CreateRequestOptions(const std::string& version) { | 150 void CreateRequestOptions(const std::string& version) { |
| 153 request_options_.reset(new TestDataReductionProxyRequestOptions( | 151 request_options_.reset(new TestDataReductionProxyRequestOptions( |
| 154 kClient, version, test_context_->config())); | 152 kClient, version, test_context_->config())); |
| 155 request_options_->Init(); | 153 request_options_->Init(); |
| 156 } | 154 } |
| 157 | 155 |
| 158 TestDataReductionProxyParams* params() { | 156 TestDataReductionProxyParams* params() { |
| (...skipping 265 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 424 DCHECK_EQ(3u, request_options()->GeneratePageId()); | 422 DCHECK_EQ(3u, request_options()->GeneratePageId()); |
| 425 | 423 |
| 426 request_options()->SetSecureSession("blah"); | 424 request_options()->SetSecureSession("blah"); |
| 427 | 425 |
| 428 DCHECK_EQ(1u, request_options()->GeneratePageId()); | 426 DCHECK_EQ(1u, request_options()->GeneratePageId()); |
| 429 DCHECK_EQ(2u, request_options()->GeneratePageId()); | 427 DCHECK_EQ(2u, request_options()->GeneratePageId()); |
| 430 DCHECK_EQ(3u, request_options()->GeneratePageId()); | 428 DCHECK_EQ(3u, request_options()->GeneratePageId()); |
| 431 } | 429 } |
| 432 | 430 |
| 433 } // namespace data_reduction_proxy | 431 } // namespace data_reduction_proxy |
| OLD | NEW |