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

Side by Side Diff: components/data_reduction_proxy/core/browser/data_reduction_proxy_configurator_unittest.cc

Issue 1086733002: Ensure tests have an active task runner (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased. Created 5 years, 7 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 "components/data_reduction_proxy/core/browser/data_reduction_proxy_conf igurator.h" 5 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_conf igurator.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/values.h" 10 #include "base/values.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 config_->GetProxyConfig().proxy_rules(); 43 config_->GetProxyConfig().proxy_rules();
44 ASSERT_EQ(expected_rules_type, rules.type); 44 ASSERT_EQ(expected_rules_type, rules.type);
45 if (net::ProxyConfig::ProxyRules::TYPE_PROXY_PER_SCHEME == 45 if (net::ProxyConfig::ProxyRules::TYPE_PROXY_PER_SCHEME ==
46 expected_rules_type) { 46 expected_rules_type) {
47 ASSERT_EQ(expected_http_proxies, rules.proxies_for_http.ToPacString()); 47 ASSERT_EQ(expected_http_proxies, rules.proxies_for_http.ToPacString());
48 ASSERT_EQ(expected_https_proxies, rules.proxies_for_https.ToPacString()); 48 ASSERT_EQ(expected_https_proxies, rules.proxies_for_https.ToPacString());
49 ASSERT_EQ(expected_bypass_list, rules.bypass_rules.ToString()); 49 ASSERT_EQ(expected_bypass_list, rules.bypass_rules.ToString());
50 } 50 }
51 } 51 }
52 52
53 base::MessageLoop message_loop_;
53 scoped_ptr<DataReductionProxyTestContext> test_context_; 54 scoped_ptr<DataReductionProxyTestContext> test_context_;
54 scoped_ptr<DataReductionProxyConfigurator> config_; 55 scoped_ptr<DataReductionProxyConfigurator> config_;
55 }; 56 };
56 57
57 TEST_F(DataReductionProxyConfiguratorTest, TestUnrestricted) { 58 TEST_F(DataReductionProxyConfiguratorTest, TestUnrestricted) {
58 config_->Enable(false, 59 config_->Enable(false,
59 false, 60 false,
60 "https://www.foo.com:443/", 61 "https://www.foo.com:443/",
61 "http://www.bar.com:80/", 62 "http://www.bar.com:80/",
62 ""); 63 "");
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 215
215 ASSERT_EQ(config_->bypass_rules_.size(), 6u); 216 ASSERT_EQ(config_->bypass_rules_.size(), 6u);
216 int i = 0; 217 int i = 0;
217 for (std::vector<std::string>::iterator it = config_->bypass_rules_.begin(); 218 for (std::vector<std::string>::iterator it = config_->bypass_rules_.begin();
218 it != config_->bypass_rules_.end(); ++it) { 219 it != config_->bypass_rules_.end(); ++it) {
219 EXPECT_EQ(expected[i++], *it); 220 EXPECT_EQ(expected[i++], *it);
220 } 221 }
221 } 222 }
222 223
223 } // namespace data_reduction_proxy 224 } // namespace data_reduction_proxy
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698