Index: ash/wm/workspace/workspace_window_resizer_unittest.cc |
diff --git a/ash/wm/workspace/workspace_window_resizer_unittest.cc b/ash/wm/workspace/workspace_window_resizer_unittest.cc |
index c049103ff3df74d401da863e91885afb84136fb5..6d6577608bc029501c5cac785d211284791f37df 100644 |
--- a/ash/wm/workspace/workspace_window_resizer_unittest.cc |
+++ b/ash/wm/workspace/workspace_window_resizer_unittest.cc |
@@ -637,6 +637,8 @@ TEST_F(WorkspaceWindowResizerTest, Edge) { |
// Test if the restore bounds is correct in multiple displays. |
window_state->ClearRestoreBounds(); |
+ // Restore to clear snapped state. |
+ window_state->Restore(); |
if (!SupportsMultipleDisplays()) |
return; |
@@ -783,8 +785,9 @@ TEST_F(WorkspaceWindowResizerTest, DontDragOffBottomWithMultiDisplay) { |
window_->SetBounds(gfx::Rect(100, 200, 300, 20)); |
DCHECK_LT(window_->bounds().height(), |
WorkspaceWindowResizer::kMinOnscreenHeight); |
+ // Drag down avoiding dragging along the edge as that would side-snap. |
scoped_ptr<WindowResizer> resizer(CreateResizerForTest( |
- window_.get(), gfx::Point(), HTCAPTION)); |
+ window_.get(), gfx::Point(10, 0), HTCAPTION)); |
ASSERT_TRUE(resizer.get()); |
resizer->Drag(CalculateDragPoint(*resizer, 0, 400), 0); |
int expected_y = kRootHeight - window_->bounds().height() - 10; |
@@ -802,8 +805,9 @@ TEST_F(WorkspaceWindowResizerTest, DontDragOffBottomWithMultiDisplay) { |
{ |
window_->SetBounds(gfx::Rect(100, 200, 300, 400)); |
scoped_ptr<WindowResizer> resizer(CreateResizerForTest( |
- window_.get(), gfx::Point(), HTCAPTION)); |
+ window_.get(), gfx::Point(10, 0), HTCAPTION)); |
ASSERT_TRUE(resizer.get()); |
+ // Drag down avoiding dragging along the edge as that would side-snap. |
resizer->Drag(CalculateDragPoint(*resizer, 0, 400), 0); |
int expected_y = |
kRootHeight - WorkspaceWindowResizer::kMinOnscreenHeight - 10; |