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

Unified Diff: chrome/browser/ui/views/accessibility/accessibility_event_router_views_unittest.cc

Issue 137993009: Remove more non-aura windows code. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: renable the disabled tests Created 6 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/ui/browser_window.h ('k') | chrome/browser/ui/views/autofill/autofill_dialog_views.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/accessibility/accessibility_event_router_views_unittest.cc
===================================================================
--- chrome/browser/ui/views/accessibility/accessibility_event_router_views_unittest.cc (revision 244775)
+++ chrome/browser/ui/views/accessibility/accessibility_event_router_views_unittest.cc (working copy)
@@ -38,20 +38,6 @@
using base::ASCIIToUTF16;
-namespace {
-
-// The expected initial focus count.
-#if defined(OS_WIN) && !defined(USE_AURA)
-// On windows (non-aura) this code triggers activating the window. Activating
-// the window triggers clearing the focus then resetting it. This results in an
-// additional focus change.
-const int kInitialFocusCount = 2;
-#else
-const int kInitialFocusCount = 1;
-#endif
-
-} // namespace
-
class AccessibilityViewsDelegate : public views::TestViewsDelegate {
public:
AccessibilityViewsDelegate() {}
@@ -281,7 +267,7 @@
base::MessageLoop::current()->RunUntilIdle();
// Test that we got the event with the expected name and context.
- EXPECT_EQ(kInitialFocusCount, control_event_count_);
+ EXPECT_EQ(1, control_event_count_);
EXPECT_EQ(kButtonNameASCII, last_control_name_);
EXPECT_EQ(kToolbarNameASCII, last_control_context_);
@@ -313,7 +299,7 @@
base::MessageLoop::current()->RunUntilIdle();
// Test that we got the event with the expected name and context.
- EXPECT_EQ(kInitialFocusCount, control_event_count_);
+ EXPECT_EQ(1, control_event_count_);
EXPECT_EQ(kButtonNameASCII, last_control_name_);
EXPECT_EQ(kAlertTextASCII, last_control_context_);
@@ -351,7 +337,7 @@
// Process anything in the event loop. Now we should get the notification,
// and it should give us the new control name, not the old one.
base::MessageLoop::current()->RunUntilIdle();
- EXPECT_EQ(kInitialFocusCount, control_event_count_);
+ EXPECT_EQ(1, control_event_count_);
EXPECT_EQ(kNewNameASCII, last_control_name_);
window->CloseNow();
« no previous file with comments | « chrome/browser/ui/browser_window.h ('k') | chrome/browser/ui/views/autofill/autofill_dialog_views.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698