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 #include "base/process_util.h" | 5 #include "base/process_util.h" |
6 #include "base/string_util.h" | 6 #include "base/string_util.h" |
7 #include "base/utf_string_conversions.h" | 7 #include "base/utf_string_conversions.h" |
8 #include "chrome/browser/ui/browser.h" | 8 #include "chrome/browser/ui/browser.h" |
9 #include "chrome/browser/ui/find_bar/find_bar_controller.h" | 9 #include "chrome/browser/ui/find_bar/find_bar_controller.h" |
10 #include "chrome/browser/ui/find_bar/find_notification_details.h" | 10 #include "chrome/browser/ui/find_bar/find_notification_details.h" |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 | 64 |
65 ViewID location_bar_focus_view_id_; | 65 ViewID location_bar_focus_view_id_; |
66 | 66 |
67 private: | 67 private: |
68 DISALLOW_COPY_AND_ASSIGN(FindInPageTest); | 68 DISALLOW_COPY_AND_ASSIGN(FindInPageTest); |
69 }; | 69 }; |
70 | 70 |
71 } // namespace | 71 } // namespace |
72 | 72 |
73 #if defined(OS_WIN) | 73 #if defined(OS_WIN) |
74 #define MAYBE_FocusRestoreOnTabSwitch DISABLED_FocusRestoreOnTabSwitch | 74 #define MAYBE_CrashEscHandlers DISABLED_CrashEscHandlers |
75 #else | 75 #else |
76 #define MAYBE_FocusRestoreOnTabSwitch FocusRestoreOnTabSwitch | 76 #define MAYBE_CrashEscHandlers CrashEscHandlers |
77 #endif | 77 #endif |
78 IN_PROC_BROWSER_TEST_F(FindInPageTest, MAYBE_CrashEscHandlers) { | 78 IN_PROC_BROWSER_TEST_F(FindInPageTest, MAYBE_CrashEscHandlers) { |
79 ASSERT_TRUE(test_server()->Start()); | 79 ASSERT_TRUE(test_server()->Start()); |
80 | 80 |
81 // First we navigate to our test page (tab A). | 81 // First we navigate to our test page (tab A). |
82 GURL url = test_server()->GetURL(kSimplePage); | 82 GURL url = test_server()->GetURL(kSimplePage); |
83 ui_test_utils::NavigateToURL(browser(), url); | 83 ui_test_utils::NavigateToURL(browser(), url); |
84 | 84 |
85 browser()->Find(); | 85 browser()->Find(); |
86 | 86 |
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
365 chrome::NOTIFICATION_FIND_RESULT_AVAILABLE, notification_source); | 365 chrome::NOTIFICATION_FIND_RESULT_AVAILABLE, notification_source); |
366 | 366 |
367 ASSERT_TRUE(ui_test_utils::SendKeyPressSync( | 367 ASSERT_TRUE(ui_test_utils::SendKeyPressSync( |
368 browser(), ui::VKEY_V, true, false, false, false)); | 368 browser(), ui::VKEY_V, true, false, false, false)); |
369 | 369 |
370 ASSERT_NO_FATAL_FAILURE(observer.Wait()); | 370 ASSERT_NO_FATAL_FAILURE(observer.Wait()); |
371 FindNotificationDetails details; | 371 FindNotificationDetails details; |
372 ASSERT_TRUE(observer.GetDetailsFor(notification_source.map_key(), &details)); | 372 ASSERT_TRUE(observer.GetDetailsFor(notification_source.map_key(), &details)); |
373 EXPECT_TRUE(details.number_of_matches() > 0); | 373 EXPECT_TRUE(details.number_of_matches() > 0); |
374 } | 374 } |
OLD | NEW |