summaryrefslogtreecommitdiffstats
path: root/views/focus/focus_manager_unittest.cc
diff options
context:
space:
mode:
authorjcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-09-22 16:06:36 +0000
committerjcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-09-22 16:06:36 +0000
commite45046ee3be4feca86640ac5ee82c5f9737f421d (patch)
treea2357685591a67e4db6eaed0fbd9b3ff7892ac2f /views/focus/focus_manager_unittest.cc
parente51eba4928e92d7d77981c1b8b48b65c1dd6df22 (diff)
downloadchromium_src-e45046ee3be4feca86640ac5ee82c5f9737f421d.zip
chromium_src-e45046ee3be4feca86640ac5ee82c5f9737f421d.tar.gz
chromium_src-e45046ee3be4feca86640ac5ee82c5f9737f421d.tar.bz2
Disabling a focus related unit test on Linux (toolkit_views).
This test fails when the screen is locked. BUG=None TEST=None TBR=nsylvain Review URL: http://codereview.chromium.org/214052 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@26813 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'views/focus/focus_manager_unittest.cc')
-rw-r--r--views/focus/focus_manager_unittest.cc10
1 files changed, 4 insertions, 6 deletions
diff --git a/views/focus/focus_manager_unittest.cc b/views/focus/focus_manager_unittest.cc
index 215ed00..29175ec 100644
--- a/views/focus/focus_manager_unittest.cc
+++ b/views/focus/focus_manager_unittest.cc
@@ -772,26 +772,25 @@ class TestTabbedPane : public TabbedPane {
// Tests that NativeControls do set the focus View appropriately on the
// FocusManager.
+// TODO(jcampan): make these tests work on the Linux build-bot. They don't work
+// when the screen is locked.
+#if defined(OS_WIN)
TEST_F(FocusManagerTest, FocusNativeControls) {
TestNativeButton* button = new TestNativeButton(L"Press me");
TestCheckbox* checkbox = new TestCheckbox(L"Checkbox");
-#if defined(OS_WIN)
TestRadioButton* radio_button = new TestRadioButton(L"RadioButton");
TestTextfield* textfield = new TestTextfield();
TestCombobox* combobox = new TestCombobox();
TestTabbedPane* tabbed_pane = new TestTabbedPane();
TestNativeButton* tab_button = new TestNativeButton(L"tab button");
-#endif
content_view_->AddChildView(button);
content_view_->AddChildView(checkbox);
-#if defined(OS_WIN)
content_view_->AddChildView(radio_button);
content_view_->AddChildView(textfield);
content_view_->AddChildView(combobox);
content_view_->AddChildView(tabbed_pane);
tabbed_pane->AddTab(L"Awesome tab", tab_button);
-#endif
// Simulate the native view getting the native focus (such as by user click).
FocusNativeView(button->TestGetNativeControlView());
@@ -800,7 +799,6 @@ TEST_F(FocusManagerTest, FocusNativeControls) {
FocusNativeView(checkbox->TestGetNativeControlView());
EXPECT_EQ(checkbox, GetFocusManager()->GetFocusedView());
-#if defined(OS_WIN)
FocusNativeView(radio_button->TestGetNativeControlView());
EXPECT_EQ(radio_button, GetFocusManager()->GetFocusedView());
@@ -815,8 +813,8 @@ TEST_F(FocusManagerTest, FocusNativeControls) {
FocusNativeView(tab_button->TestGetNativeControlView());
EXPECT_EQ(tab_button, GetFocusManager()->GetFocusedView());
-#endif
}
+#endif
// Test that when activating/deactivating the top window, the focus is stored/
// restored properly.