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

Side by Side Diff: chrome/common/extensions/extension_permission_set_unittest.cc

Issue 9274004: Take the Extension Storage API out of experimental. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 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 | Annotate | Revision Log
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 #include "chrome/common/extensions/extension_permission_set.h" 5 #include "chrome/common/extensions/extension_permission_set.h"
6 6
7 #include "base/json/json_value_serializer.h" 7 #include "base/json/json_value_serializer.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/path_service.h" 9 #include "base/path_service.h"
10 #include "base/utf_string_conversions.h" 10 #include "base/utf_string_conversions.h"
(...skipping 623 matching lines...) Expand 10 before | Expand all | Expand 10 after
634 // strings associated with them. 634 // strings associated with them.
635 ExtensionAPIPermissionSet skip; 635 ExtensionAPIPermissionSet skip;
636 636
637 // These are considered "nuisance" or "trivial" permissions that don't need 637 // These are considered "nuisance" or "trivial" permissions that don't need
638 // a prompt. 638 // a prompt.
639 skip.insert(ExtensionAPIPermission::kAppNotifications); 639 skip.insert(ExtensionAPIPermission::kAppNotifications);
640 skip.insert(ExtensionAPIPermission::kContextMenus); 640 skip.insert(ExtensionAPIPermission::kContextMenus);
641 skip.insert(ExtensionAPIPermission::kIdle); 641 skip.insert(ExtensionAPIPermission::kIdle);
642 skip.insert(ExtensionAPIPermission::kNotification); 642 skip.insert(ExtensionAPIPermission::kNotification);
643 skip.insert(ExtensionAPIPermission::kUnlimitedStorage); 643 skip.insert(ExtensionAPIPermission::kUnlimitedStorage);
644 skip.insert(ExtensionAPIPermission::kStorage);
644 skip.insert(ExtensionAPIPermission::kTts); 645 skip.insert(ExtensionAPIPermission::kTts);
645 646
646 // TODO(erikkay) add a string for this permission. 647 // TODO(erikkay) add a string for this permission.
647 skip.insert(ExtensionAPIPermission::kBackground); 648 skip.insert(ExtensionAPIPermission::kBackground);
648 649
649 skip.insert(ExtensionAPIPermission::kClipboardWrite); 650 skip.insert(ExtensionAPIPermission::kClipboardWrite);
650 651
651 // The cookie permission does nothing unless you have associated host 652 // The cookie permission does nothing unless you have associated host
652 // permissions. 653 // permissions.
653 skip.insert(ExtensionAPIPermission::kCookie); 654 skip.insert(ExtensionAPIPermission::kCookie);
(...skipping 509 matching lines...) Expand 10 before | Expand all | Expand 10 after
1163 AddPattern(&non_empty_extent, "http://www.google.com/*"); 1164 AddPattern(&non_empty_extent, "http://www.google.com/*");
1164 1165
1165 perm_set = new ExtensionPermissionSet( 1166 perm_set = new ExtensionPermissionSet(
1166 empty_apis, non_empty_extent, empty_extent); 1167 empty_apis, non_empty_extent, empty_extent);
1167 EXPECT_FALSE(perm_set->IsEmpty()); 1168 EXPECT_FALSE(perm_set->IsEmpty());
1168 1169
1169 perm_set = new ExtensionPermissionSet( 1170 perm_set = new ExtensionPermissionSet(
1170 empty_apis, empty_extent, non_empty_extent); 1171 empty_apis, empty_extent, non_empty_extent);
1171 EXPECT_FALSE(perm_set->IsEmpty()); 1172 EXPECT_FALSE(perm_set->IsEmpty());
1172 } 1173 }
OLDNEW
« no previous file with comments | « chrome/common/extensions/extension_permission_set.cc ('k') | chrome/renderer/extensions/custom_bindings_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698