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 <map> | 5 #include <map> |
6 #include <vector> | 6 #include <vector> |
7 | 7 |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "chrome/browser/extensions/extension_apitest.h" | 10 #include "chrome/browser/extensions/extension_apitest.h" |
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
167 size_t GetScanRequested() { return scan_requested_.size(); } | 167 size_t GetScanRequested() { return scan_requested_.size(); } |
168 | 168 |
169 void DictionaryResult(const std::string& guid, | 169 void DictionaryResult(const std::string& guid, |
170 const DictionaryCallback& success_callback, | 170 const DictionaryCallback& success_callback, |
171 const FailureCallback& failure_callback) { | 171 const FailureCallback& failure_callback) { |
172 if (fail_) { | 172 if (fail_) { |
173 failure_callback.Run(kFailure); | 173 failure_callback.Run(kFailure); |
174 } else { | 174 } else { |
175 scoped_ptr<base::DictionaryValue> result(new base::DictionaryValue); | 175 scoped_ptr<base::DictionaryValue> result(new base::DictionaryValue); |
176 result->SetString(::onc::network_config::kGUID, guid); | 176 result->SetString(::onc::network_config::kGUID, guid); |
| 177 result->SetString(::onc::network_config::kType, |
| 178 ::onc::network_config::kWiFi); |
177 success_callback.Run(result.Pass()); | 179 success_callback.Run(result.Pass()); |
178 } | 180 } |
179 } | 181 } |
180 | 182 |
181 void StringResult(const StringCallback& success_callback, | 183 void StringResult(const StringCallback& success_callback, |
182 const FailureCallback& failure_callback) { | 184 const FailureCallback& failure_callback) { |
183 if (fail_) { | 185 if (fail_) { |
184 failure_callback.Run(kFailure); | 186 failure_callback.Run(kFailure); |
185 } else { | 187 } else { |
186 success_callback.Run(kSuccess); | 188 success_callback.Run(kSuccess); |
(...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
495 EXPECT_FALSE(RunNetworkingSubtest("getWifiTDLSStatus")) << message_; | 497 EXPECT_FALSE(RunNetworkingSubtest("getWifiTDLSStatus")) << message_; |
496 } | 498 } |
497 | 499 |
498 IN_PROC_BROWSER_TEST_F(NetworkingPrivateApiTestFail, GetCaptivePortalStatus) { | 500 IN_PROC_BROWSER_TEST_F(NetworkingPrivateApiTestFail, GetCaptivePortalStatus) { |
499 EXPECT_FALSE(RunNetworkingSubtest("getCaptivePortalStatus")) << message_; | 501 EXPECT_FALSE(RunNetworkingSubtest("getCaptivePortalStatus")) << message_; |
500 } | 502 } |
501 | 503 |
502 #endif // defined(OS_WIN) | 504 #endif // defined(OS_WIN) |
503 | 505 |
504 } // namespace extensions | 506 } // namespace extensions |
OLD | NEW |