OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/ui/browser.h" | 5 #include "chrome/browser/ui/browser.h" |
6 #include "chrome/browser/ui/browser_commands_mac.h" | 6 #include "chrome/browser/ui/browser_commands_mac.h" |
7 #import "chrome/browser/ui/cocoa/website_settings/permission_bubble_cocoa.h" | 7 #import "chrome/browser/ui/cocoa/permission_bubble/permission_bubble_cocoa.h" |
8 #import "chrome/browser/ui/cocoa/website_settings/permission_bubble_controller.h
" | 8 #import "chrome/browser/ui/cocoa/permission_bubble/permission_bubble_controller.
h" |
9 #include "chrome/browser/ui/exclusive_access/fullscreen_controller.h" | 9 #include "chrome/browser/ui/exclusive_access/fullscreen_controller.h" |
| 10 #include "chrome/browser/ui/permission_bubble/permission_bubble_browser_test_uti
l.h" |
10 #include "chrome/browser/ui/tabs/tab_strip_model.h" | 11 #include "chrome/browser/ui/tabs/tab_strip_model.h" |
11 #include "chrome/browser/ui/website_settings/permission_bubble_browser_test_util
.h" | |
12 #include "chrome/common/pref_names.h" | 12 #include "chrome/common/pref_names.h" |
13 #include "components/prefs/pref_service.h" | 13 #include "components/prefs/pref_service.h" |
14 #import "testing/gtest_mac.h" | 14 #import "testing/gtest_mac.h" |
15 #include "ui/base/test/scoped_fake_nswindow_fullscreen.h" | 15 #include "ui/base/test/scoped_fake_nswindow_fullscreen.h" |
16 | 16 |
17 IN_PROC_BROWSER_TEST_F(PermissionBubbleBrowserTest, HasLocationBarByDefault) { | 17 IN_PROC_BROWSER_TEST_F(PermissionBubbleBrowserTest, HasLocationBarByDefault) { |
18 PermissionBubbleCocoa bubble(browser()); | 18 PermissionBubbleCocoa bubble(browser()); |
19 bubble.SetDelegate(test_delegate()); | 19 bubble.SetDelegate(test_delegate()); |
20 bubble.Show(requests(), accept_states()); | 20 bubble.Show(requests(), accept_states()); |
21 EXPECT_TRUE([bubble.bubbleController_ hasVisibleLocationBar]); | 21 EXPECT_TRUE([bubble.bubbleController_ hasVisibleLocationBar]); |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
91 // http://crbug.com/470724 | 91 // http://crbug.com/470724 |
92 // Kiosk mode on Mac has a location bar but it shouldn't. | 92 // Kiosk mode on Mac has a location bar but it shouldn't. |
93 IN_PROC_BROWSER_TEST_F(PermissionBubbleKioskBrowserTest, | 93 IN_PROC_BROWSER_TEST_F(PermissionBubbleKioskBrowserTest, |
94 DISABLED_KioskHasNoLocationBar) { | 94 DISABLED_KioskHasNoLocationBar) { |
95 PermissionBubbleCocoa bubble(browser()); | 95 PermissionBubbleCocoa bubble(browser()); |
96 bubble.SetDelegate(test_delegate()); | 96 bubble.SetDelegate(test_delegate()); |
97 bubble.Show(requests(), accept_states()); | 97 bubble.Show(requests(), accept_states()); |
98 EXPECT_FALSE([bubble.bubbleController_ hasVisibleLocationBar]); | 98 EXPECT_FALSE([bubble.bubbleController_ hasVisibleLocationBar]); |
99 bubble.Hide(); | 99 bubble.Hide(); |
100 } | 100 } |
OLD | NEW |