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

Side by Side Diff: chrome/browser/extensions/api/networking_private/networking_private_apitest.cc

Issue 1036033002: Add types to networkigPrivate IDL (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@issue_470262_networking_private_idl_1
Patch Set: Fix apitest, test.js nits Created 5 years, 8 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
« no previous file with comments | « no previous file | chrome/browser/resources/chromeos/network_ui/network_ui.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 <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
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
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
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/resources/chromeos/network_ui/network_ui.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698