OLD | NEW |
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 #import "chrome/browser/ui/cocoa/content_settings/content_setting_bubble_cocoa.h
" | 5 #import "chrome/browser/ui/cocoa/content_settings/content_setting_bubble_cocoa.h
" |
6 | 6 |
7 #import <Cocoa/Cocoa.h> | 7 #import <Cocoa/Cocoa.h> |
8 | 8 |
9 #include "base/debug/debugger.h" | 9 #include "base/debug/debugger.h" |
10 #include "base/mac/scoped_nsautorelease_pool.h" | 10 #include "base/mac/scoped_nsautorelease_pool.h" |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 ContentSettingBubbleControllerTest::ContentSettingBubbleControllerTest() | 49 ContentSettingBubbleControllerTest::ContentSettingBubbleControllerTest() |
50 : ChromeRenderViewHostTestHarness(), | 50 : ChromeRenderViewHostTestHarness(), |
51 browser_thread_(BrowserThread::UI, &message_loop_) { | 51 browser_thread_(BrowserThread::UI, &message_loop_) { |
52 } | 52 } |
53 | 53 |
54 ContentSettingBubbleControllerTest::~ContentSettingBubbleControllerTest() { | 54 ContentSettingBubbleControllerTest::~ContentSettingBubbleControllerTest() { |
55 } | 55 } |
56 | 56 |
57 // Check that the bubble doesn't crash or leak for any settings type | 57 // Check that the bubble doesn't crash or leak for any settings type |
58 // Disabled: started failing after CONTENT_SETTINGS_TYPE_INTENTS was removed. | 58 // Disabled: started failing after CONTENT_SETTINGS_TYPE_INTENTS was removed. |
59 // https://code.google.com/p/chromium/issues/detail?id=175629 | 59 TEST_F(ContentSettingBubbleControllerTest, Init) { |
60 TEST_F(ContentSettingBubbleControllerTest, DISABLED_Init) { | |
61 for (int i = 0; i < CONTENT_SETTINGS_NUM_TYPES; ++i) { | 60 for (int i = 0; i < CONTENT_SETTINGS_NUM_TYPES; ++i) { |
62 if (i == CONTENT_SETTINGS_TYPE_NOTIFICATIONS || | 61 if (i == CONTENT_SETTINGS_TYPE_NOTIFICATIONS || |
63 i == CONTENT_SETTINGS_TYPE_AUTO_SELECT_CERTIFICATE || | 62 i == CONTENT_SETTINGS_TYPE_AUTO_SELECT_CERTIFICATE || |
64 i == CONTENT_SETTINGS_TYPE_FULLSCREEN || | 63 i == CONTENT_SETTINGS_TYPE_FULLSCREEN || |
65 i == CONTENT_SETTINGS_TYPE_MOUSELOCK || | 64 i == CONTENT_SETTINGS_TYPE_MOUSELOCK || |
66 i == CONTENT_SETTINGS_TYPE_MEDIASTREAM_MIC || | 65 i == CONTENT_SETTINGS_TYPE_MEDIASTREAM_MIC || |
67 i == CONTENT_SETTINGS_TYPE_MEDIASTREAM_CAMERA || | 66 i == CONTENT_SETTINGS_TYPE_MEDIASTREAM_CAMERA || |
68 i == CONTENT_SETTINGS_TYPE_PPAPI_BROKER) { | 67 i == CONTENT_SETTINGS_TYPE_PPAPI_BROKER) { |
69 // These types have no bubble. | 68 // These types have no bubble. |
70 continue; | 69 continue; |
(...skipping 18 matching lines...) Expand all Loading... |
89 settingsType) | 88 settingsType) |
90 parentWindow:parent | 89 parentWindow:parent |
91 anchoredAt:NSMakePoint(50, 20)]; | 90 anchoredAt:NSMakePoint(50, 20)]; |
92 EXPECT_TRUE(controller != nil); | 91 EXPECT_TRUE(controller != nil); |
93 EXPECT_TRUE([[controller window] isVisible]); | 92 EXPECT_TRUE([[controller window] isVisible]); |
94 [parent close]; | 93 [parent close]; |
95 } | 94 } |
96 } | 95 } |
97 | 96 |
98 } // namespace | 97 } // namespace |
OLD | NEW |