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

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

Issue 2801173002: arc: Provide API to control Play Store state from autotests (Closed)
Patch Set: nits Created 3 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 chrome.test.runTests([ 5 chrome.test.runTests([
6 // logout/restart/shutdown don't do anything as we don't want to kill the 6 // logout/restart/shutdown don't do anything as we don't want to kill the
7 // browser with these tests. 7 // browser with these tests.
8 function logout() { 8 function logout() {
9 chrome.autotestPrivate.logout(); 9 chrome.autotestPrivate.logout();
10 chrome.test.succeed(); 10 chrome.test.succeed();
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 chrome.autotestPrivate.setMouseSensitivity(3); 101 chrome.autotestPrivate.setMouseSensitivity(3);
102 chrome.test.succeed(); 102 chrome.test.succeed();
103 }, 103 },
104 function setPrimaryButtonRight() { 104 function setPrimaryButtonRight() {
105 chrome.autotestPrivate.setPrimaryButtonRight(false); 105 chrome.autotestPrivate.setPrimaryButtonRight(false);
106 chrome.test.succeed(); 106 chrome.test.succeed();
107 }, 107 },
108 function getVisibleNotifications() { 108 function getVisibleNotifications() {
109 chrome.autotestPrivate.getVisibleNotifications(function(){}); 109 chrome.autotestPrivate.getVisibleNotifications(function(){});
110 chrome.test.succeed(); 110 chrome.test.succeed();
111 },
112 function getPlayStoreState() {
113 chrome.autotestPrivate.getPlayStoreState(function(state) {
114 // By default ARC is not available. Field allowed must be set to false;
115 // managed and enabled should be underfined.
116 chrome.test.assertFalse(state.allowed);
117 chrome.test.assertEq(undefined, state.enabled);
118 chrome.test.assertEq(undefined, state.managed);
119 chrome.test.succeed();
120 });
121 },
122 function setPlayStoreEnabled() {
123 chrome.autotestPrivate.setPlayStoreEnabled(false, function() {
124 // By default ARC is not available.
125 chrome.test.assertTrue(chrome.runtime.lastError != undefined);
126 chrome.test.succeed();
127 });
111 } 128 }
112 ]); 129 ]);
OLDNEW
« no previous file with comments | « chrome/common/extensions/api/autotest_private.idl ('k') | extensions/browser/extension_function_histogram_value.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698