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

Side by Side Diff: chrome/test/data/extensions/api_test/networking_private/alias/test.js

Issue 2628673002: Enable networking.onc for autolaunched kiosk sessions (on dev) (Closed)
Patch Set: . Created 3 years, 11 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 | extensions/browser/api/networking_private/networking_private_api.cc » ('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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 // Test that verifies that apps with only networking API alias permission 5 // Test that verifies that apps with only networking API alias permission
6 // can invoke API methods and listen to API events without encountering 6 // can invoke API methods and listen to API events without encountering
7 // API access problems. 7 // API access problems.
8 8
9 chrome.test.runTests([ 9 chrome.test.runTests([
10 function onlyAliasBindingsPresent() { 10 function onlyAliasBindingsPresent() {
(...skipping 26 matching lines...) Expand all
37 }, 37 },
38 function verifyConnectionStateChanged() { 38 function verifyConnectionStateChanged() {
39 chrome.networking.onc.getProperties( 39 chrome.networking.onc.getProperties(
40 'stub_wifi1_guid', 40 'stub_wifi1_guid',
41 chrome.test.callbackPass(function(result) { 41 chrome.test.callbackPass(function(result) {
42 chrome.test.assertEq('stub_wifi1_guid', result.GUID); 42 chrome.test.assertEq('stub_wifi1_guid', result.GUID);
43 chrome.test.assertFalse( 43 chrome.test.assertFalse(
44 result.ConnectionState == 44 result.ConnectionState ==
45 chrome.networking.onc.ConnectionStateType.CONNECTED); 45 chrome.networking.onc.ConnectionStateType.CONNECTED);
46 })); 46 }));
47 },
48 function verifyNoAccessToNetworkingPrivateOnlyMethods() {
49 var expectedError = 'Requires networkingPrivate API access.';
50 chrome.networking.onc.getVisibleNetworks('All',
51 chrome.test.callbackFail(expectedError));
52 chrome.networking.onc.getEnabledNetworkTypes(
53 chrome.test.callbackFail(expectedError));
54 var stubVerificationProperties = {
55 certificate: '',
56 publicKey: '',
57 nonce: '',
58 signedData: '',
59 deviceSerial: '',
60 deviceSsid: '',
61 deviceBssid: ''
62 };
63 chrome.networking.onc.verifyDestination(
64 stubVerificationProperties, chrome.test.callbackFail(expectedError));
65 chrome.networking.onc.verifyAndEncryptCredentials(
66 stubVerificationProperties, '',
67 chrome.test.callbackFail(expectedError));
68 chrome.networking.onc.verifyAndEncryptData(
69 stubVerificationProperties, '',
70 chrome.test.callbackFail(expectedError));
71 chrome.networking.onc.setWifiTDLSEnabledState('', false,
72 chrome.test.callbackFail(expectedError));
73 chrome.networking.onc.getWifiTDLSStatus('',
74 chrome.test.callbackFail(expectedError));
47 } 75 }
48 ]); 76 ]);
OLDNEW
« no previous file with comments | « no previous file | extensions/browser/api/networking_private/networking_private_api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698