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 "content/browser/web_contents/web_contents_view_aura.h" | 5 #include "content/browser/web_contents/web_contents_view_aura.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/run_loop.h" | 8 #include "base/run_loop.h" |
9 #include "base/test/test_timeouts.h" | 9 #include "base/test/test_timeouts.h" |
10 #include "base/utf_string_conversions.h" | 10 #include "base/utf_string_conversions.h" |
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
185 value = content::ExecuteScriptAndGetValue(view_host, "get_current()"); | 185 value = content::ExecuteScriptAndGetValue(view_host, "get_current()"); |
186 if (!value->GetAsInteger(&index)) | 186 if (!value->GetAsInteger(&index)) |
187 index = -1; | 187 index = -1; |
188 return index; | 188 return index; |
189 } | 189 } |
190 | 190 |
191 private: | 191 private: |
192 DISALLOW_COPY_AND_ASSIGN(WebContentsViewAuraTest); | 192 DISALLOW_COPY_AND_ASSIGN(WebContentsViewAuraTest); |
193 }; | 193 }; |
194 | 194 |
| 195 // Disabled OverscrollNavigation tests because they started failing after the |
| 196 // 142795->142840 webkit roll (http://crbug.com/176266). |
195 IN_PROC_BROWSER_TEST_F(WebContentsViewAuraTest, | 197 IN_PROC_BROWSER_TEST_F(WebContentsViewAuraTest, |
196 OverscrollNavigation) { | 198 DISABLED_OverscrollNavigation) { |
197 TestOverscrollNavigation(false); | 199 TestOverscrollNavigation(false); |
198 } | 200 } |
199 | 201 |
200 IN_PROC_BROWSER_TEST_F(WebContentsViewAuraTest, | 202 IN_PROC_BROWSER_TEST_F(WebContentsViewAuraTest, |
201 OverscrollNavigationWithTouchHandler) { | 203 DISABLED_OverscrollNavigationWithTouchHandler) { |
202 TestOverscrollNavigation(true); | 204 TestOverscrollNavigation(true); |
203 } | 205 } |
204 | 206 |
205 IN_PROC_BROWSER_TEST_F(WebContentsViewAuraTest, | 207 IN_PROC_BROWSER_TEST_F(WebContentsViewAuraTest, |
206 QuickOverscrollDirectionChange) { | 208 QuickOverscrollDirectionChange) { |
207 ASSERT_NO_FATAL_FAILURE( | 209 ASSERT_NO_FATAL_FAILURE( |
208 StartTestWithPage("files/overscroll_navigation.html")); | 210 StartTestWithPage("files/overscroll_navigation.html")); |
209 WebContentsImpl* web_contents = | 211 WebContentsImpl* web_contents = |
210 static_cast<WebContentsImpl*>(shell()->web_contents()); | 212 static_cast<WebContentsImpl*>(shell()->web_contents()); |
211 RenderViewHostImpl* view_host = static_cast<RenderViewHostImpl*>( | 213 RenderViewHostImpl* view_host = static_cast<RenderViewHostImpl*>( |
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
408 web_contents->GetController().GetEntryAtOffset(-1)); | 410 web_contents->GetController().GetEntryAtOffset(-1)); |
409 EXPECT_TRUE(entry->screenshot().get()); | 411 EXPECT_TRUE(entry->screenshot().get()); |
410 | 412 |
411 entry = NavigationEntryImpl::FromNavigationEntry( | 413 entry = NavigationEntryImpl::FromNavigationEntry( |
412 web_contents->GetController().GetActiveEntry()); | 414 web_contents->GetController().GetActiveEntry()); |
413 EXPECT_FALSE(entry->screenshot().get()); | 415 EXPECT_FALSE(entry->screenshot().get()); |
414 } | 416 } |
415 } | 417 } |
416 | 418 |
417 } // namespace content | 419 } // namespace content |
OLD | NEW |