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

Unified Diff: chrome/test/data/extensions/management/themes/undo2.js

Issue 6546072: Clean up how we handle themes in the extensions system and management API.... Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 9 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: chrome/test/data/extensions/management/themes/undo2.js
===================================================================
--- chrome/test/data/extensions/management/themes/undo2.js (revision 0)
+++ chrome/test/data/extensions/management/themes/undo2.js (revision 0)
@@ -0,0 +1,33 @@
+// 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.
+
+
+var test_steps = [
+ ["enable", "iamefpfkojoapidjnbafmgkgncegbkad"],
+ ["disable", "pjpgmfcmabopnnfonnhmdjglfpjjfkbf"],
+ send("step1")
+];
+
+chrome.management.getAll(function(items) {
+ var enabled_theme = null;
+ for (var i = 0; i < items.length; i++) {
+ var item = items[i];
+ if (!item.isTheme) {
+ continue;
+ }
+ if (item.enabled) {
+ if (enabled_theme) {
+ console.log("error: more than 1 enabled theme!");
+ return;
+ }
+ enabled_theme = item;
+ }
+ }
+ if (enabled_theme.id != "pjpgmfcmabopnnfonnhmdjglfpjjfkbf") {
+ console.log("Found unexpected theme enabled : " + enabled_theme.id);
+ return;
+ }
+ chrome.test.sendMessage("ready");
+});
+
Property changes on: chrome/test/data/extensions/management/themes/undo2.js
___________________________________________________________________
Added: svn:eol-style
+ LF
« no previous file with comments | « chrome/test/data/extensions/management/themes/undo.js ('k') | chrome/test/data/extensions/management/themes/uninstall.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698