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

Side by Side Diff: chrome/browser/extensions/notifications_apitest.cc

Issue 7918019: Change the URL for the Extension Settings page from chrome://settings/extensionSettings to chrome... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 3 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/browser/extensions/extension_apitest.h" 5 #include "chrome/browser/extensions/extension_apitest.h"
6 6
7 #include "chrome/browser/notifications/desktop_notification_service.h" 7 #include "chrome/browser/notifications/desktop_notification_service.h"
8 #include "chrome/browser/notifications/desktop_notification_service_factory.h" 8 #include "chrome/browser/notifications/desktop_notification_service_factory.h"
9 #include "chrome/browser/profiles/profile.h" 9 #include "chrome/browser/profiles/profile.h"
10 #include "chrome/browser/ui/browser.h" 10 #include "chrome/browser/ui/browser.h"
11 11
12 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, Notifications) { 12 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, NotificationsNoPermission) {
13 #if defined(OS_LINUX) && defined(TOOLKIT_VIEWS) 13 #if defined(OS_LINUX) && defined(TOOLKIT_VIEWS)
14 // Notifications not supported on linux/views yet. 14 // Notifications not supported on linux/views yet.
15 #else 15 #else
16 ASSERT_TRUE(RunExtensionTest("notifications/has_not_permission")) << message_; 16 ASSERT_TRUE(RunExtensionTest("notifications/has_not_permission")) << message_;
17 #endif
18 }
19
20 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, NotificationsHasPermissionManifest) {
21 #if defined(OS_LINUX) && defined(TOOLKIT_VIEWS)
22 // Notifications not supported on linux/views yet.
rafaelw 2011/09/19 18:12:00 indent
23 #else
17 ASSERT_TRUE(RunExtensionTest("notifications/has_permission_manifest")) 24 ASSERT_TRUE(RunExtensionTest("notifications/has_permission_manifest"))
18 << message_; 25 << message_;
26 #endif
27 }
28
29 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, NotificationsHasPermission) {
30 #if defined(OS_LINUX) && defined(TOOLKIT_VIEWS)
31 // Notifications not supported on linux/views yet.
rafaelw 2011/09/19 18:12:00 indent
32 #else
19 DesktopNotificationServiceFactory::GetForProfile(browser()->profile()) 33 DesktopNotificationServiceFactory::GetForProfile(browser()->profile())
20 ->GrantPermission(GURL( 34 ->GrantPermission(GURL(
21 "chrome-extension://peoadpeiejnhkmpaakpnompolbglelel")); 35 "chrome-extension://peoadpeiejnhkmpaakpnompolbglelel"));
22 ASSERT_TRUE(RunExtensionTest("notifications/has_permission_prefs")) 36 ASSERT_TRUE(RunExtensionTest("notifications/has_permission_prefs"))
23 << message_; 37 << message_;
24 #endif 38 #endif
25 } 39 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_management_browsertest.cc ('k') | chrome/browser/resources/options/extension_settings.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698