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

Unified Diff: chrome/test/data/extensions/api_test/context_menus/no_perms/test.js

Issue 2840038: Move context menu module out of experimental. (Closed) Base URL: git://codf21.jail/chromium.git
Patch Set: kathy changes Created 10 years, 5 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/api_test/context_menus/no_perms/test.js
diff --git a/chrome/test/data/extensions/api_test/context_menus/no_perms/test.js b/chrome/test/data/extensions/api_test/context_menus/no_perms/test.js
new file mode 100644
index 0000000000000000000000000000000000000000..ca9a60e7b828cbd1560612a1ad4944d78bcfec4c
--- /dev/null
+++ b/chrome/test/data/extensions/api_test/context_menus/no_perms/test.js
@@ -0,0 +1,21 @@
+// Copyright (c) 2010 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 tests = [
+ function simple() {
+ try {
+ chrome.contextMenus.create({"title":"1"}, function() {
+ });
+ } catch (e) {
+ chrome.test.assertTrue(e.message.indexOf(
+ "You do not have permission to use 'contextMenus.create'") == 0);
+ chrome.test.succeed();
+ return;
+ }
+
+ chrome.test.fail("Should have gotten access error.");
+ }
+];
+
+chrome.test.runTests(tests);

Powered by Google App Engine
This is Rietveld 408576698