Index: ui/views/widget/widget_unittest.cc |
diff --git a/ui/views/widget/widget_unittest.cc b/ui/views/widget/widget_unittest.cc |
index f68663bd1cf29c00fc2877a515d488d7517af1c2..874ebe9f4aceae1a964a1e03c4b3a0721970da7e 100644 |
--- a/ui/views/widget/widget_unittest.cc |
+++ b/ui/views/widget/widget_unittest.cc |
@@ -3269,8 +3269,7 @@ SubclassWindowHelper* SubclassWindowHelper::instance_ = nullptr; |
// 1. Posting a WM_NCMOUSEMOVE message for a different location. |
// 2. Posting a WM_NCMOUSEMOVE message with a different hittest code. |
// 3. Posting a WM_MOUSEMOVE message. |
-// Disabled because of flaky timeouts: http://crbug.com/592742 |
-TEST_F(WidgetTest, DISABLED_SysCommandMoveOnNCLButtonDownOnCaptionAndMoveTest) { |
+TEST_F(WidgetTest, SysCommandMoveOnNCLButtonDownOnCaptionAndMoveTest) { |
Widget widget; |
Widget::InitParams params = |
CreateParams(Widget::InitParams::TYPE_WINDOW); |
@@ -3280,7 +3279,7 @@ TEST_F(WidgetTest, DISABLED_SysCommandMoveOnNCLButtonDownOnCaptionAndMoveTest) { |
widget.Init(params); |
widget.SetBounds(gfx::Rect(0, 0, 200, 200)); |
widget.Show(); |
- ::SetCursorPos(500, 500); |
+ RunPendingMessages(); |
HWND window = widget.GetNativeWindow()->GetHost()->GetAcceleratedWidget(); |
@@ -3290,6 +3289,7 @@ TEST_F(WidgetTest, DISABLED_SysCommandMoveOnNCLButtonDownOnCaptionAndMoveTest) { |
// WM_SYSCOMMAND |
::PostMessage(window, WM_NCLBUTTONDOWN, HTCAPTION, MAKELPARAM(100, 100)); |
RunPendingMessages(); |
+ |
EXPECT_TRUE(subclass_helper.received_message(WM_NCLBUTTONDOWN)); |
EXPECT_FALSE(subclass_helper.received_message(WM_SYSCOMMAND)); |
@@ -3343,8 +3343,7 @@ TEST_F(WidgetTest, DISABLED_SysCommandMoveOnNCLButtonDownOnCaptionAndMoveTest) { |
// This test validates that destroying the window in the context of the |
// WM_SYSCOMMAND message with SC_MOVE does not crash. |
-// Disabled because of flaky timeouts: http://crbug.com/592742 |
-TEST_F(WidgetTest, DISABLED_DestroyInSysCommandNCLButtonDownOnCaption) { |
+TEST_F(WidgetTest, DestroyInSysCommandNCLButtonDownOnCaption) { |
Widget widget; |
Widget::InitParams params = |
CreateParams(Widget::InitParams::TYPE_WINDOW); |
@@ -3354,7 +3353,7 @@ TEST_F(WidgetTest, DISABLED_DestroyInSysCommandNCLButtonDownOnCaption) { |
widget.Init(params); |
widget.SetBounds(gfx::Rect(0, 0, 200, 200)); |
widget.Show(); |
- ::SetCursorPos(500, 500); |
+ RunPendingMessages(); |
HWND window = widget.GetNativeWindow()->GetHost()->GetAcceleratedWidget(); |