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

Unified Diff: chrome/test/data/extensions/api_test/accessibility_private/get_update_status/background.js

Issue 8747003: Add private system extension API to get system update status (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Codereview Created 9 years, 1 month 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 side-by-side diff with in-line comments
Download patch
Index: chrome/test/data/extensions/api_test/accessibility_private/get_update_status/background.js
diff --git a/chrome/test/data/extensions/api_test/accessibility_private/get_update_status/background.js b/chrome/test/data/extensions/api_test/accessibility_private/get_update_status/background.js
new file mode 100644
index 0000000000000000000000000000000000000000..7d0fd4a1e5d956e570a4df5bafad19b961aeecba
--- /dev/null
+++ b/chrome/test/data/extensions/api_test/accessibility_private/get_update_status/background.js
@@ -0,0 +1,30 @@
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// accessibiiltyPrivate.getUpdateStatus test for Chrome on ChromeOS.
+// browser_tests --gtest_filter="AccessibilityPrivateApiTest.GetUpdateStatus"
+
+chrome.test.runTests([
+ function notAvailable() {
+ chrome.accessibilityPrivate.getUpdateStatus(function(status) {
+ chrome.test.assertEq(status.state, "NotAvailable");
+ chrome.test.assertEq(status.download_progress, 0.0);
+ chrome.test.succeed();
+ });
+ },
+ function updating() {
+ chrome.accessibilityPrivate.getUpdateStatus(function(status) {
+ chrome.test.assertEq(status.state, "Updating");
+ chrome.test.assertEq(status.download_progress, 0.5);
+ chrome.test.succeed();
+ });
+ },
+ function needReboot() {
+ chrome.accessibilityPrivate.getUpdateStatus(function(status) {
+ chrome.test.assertEq(status.state, "NeedReboot");
+ chrome.test.assertEq(status.download_progress, 1);
+ chrome.test.succeed();
+ });
+ }
+]);

Powered by Google App Engine
This is Rietveld 408576698