| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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/command_line.h" | 5 #include "base/command_line.h" |
| 6 #include "base/file_util.h" | 6 #include "base/file_util.h" |
| 7 #include "base/gfx/rect.h" | 7 #include "base/gfx/rect.h" |
| 8 #include "chrome/app/chrome_dll_resource.h" | 8 #include "chrome/app/chrome_dll_resource.h" |
| 9 #include "chrome/browser/view_ids.h" | 9 #include "chrome/browser/view_ids.h" |
| 10 #include "chrome/common/chrome_paths.h" | 10 #include "chrome/common/chrome_paths.h" |
| (...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 230 GURL tab3_new_url; | 230 GURL tab3_new_url; |
| 231 ASSERT_TRUE(tab3->GetCurrentURL(&tab3_new_url)); | 231 ASSERT_TRUE(tab3->GetCurrentURL(&tab3_new_url)); |
| 232 | 232 |
| 233 EXPECT_EQ(tab1_new_url.spec(), tab2_url.spec()); | 233 EXPECT_EQ(tab1_new_url.spec(), tab2_url.spec()); |
| 234 EXPECT_EQ(tab2_new_url.spec(), tab3_url.spec()); | 234 EXPECT_EQ(tab2_new_url.spec(), tab3_url.spec()); |
| 235 EXPECT_EQ(tab3_new_url.spec(), tab1_url.spec()); | 235 EXPECT_EQ(tab3_new_url.spec(), tab1_url.spec()); |
| 236 } | 236 } |
| 237 | 237 |
| 238 // Drag Tab_1 into the position of Tab_3, and press ESCAPE before releasing the | 238 // Drag Tab_1 into the position of Tab_3, and press ESCAPE before releasing the |
| 239 // left mouse button. | 239 // left mouse button. |
| 240 TEST_F(TabDraggingTest, Tab1Tab3Escape) { | 240 // Flaky, see http://crbug.com/21092. |
| 241 TEST_F(TabDraggingTest, DISABLED_Tab1Tab3Escape) { |
| 241 scoped_refptr<BrowserProxy> browser(automation()->GetBrowserWindow(0)); | 242 scoped_refptr<BrowserProxy> browser(automation()->GetBrowserWindow(0)); |
| 242 ASSERT_TRUE(browser.get()); | 243 ASSERT_TRUE(browser.get()); |
| 243 scoped_refptr<WindowProxy> window(browser->GetWindow()); | 244 scoped_refptr<WindowProxy> window(browser->GetWindow()); |
| 244 ASSERT_TRUE(window.get()); | 245 ASSERT_TRUE(window.get()); |
| 245 | 246 |
| 246 // Get initial tab count. | 247 // Get initial tab count. |
| 247 int initial_tab_count = 0; | 248 int initial_tab_count = 0; |
| 248 ASSERT_TRUE(browser->GetTabCount(&initial_tab_count)); | 249 ASSERT_TRUE(browser->GetTabCount(&initial_tab_count)); |
| 249 ASSERT_TRUE(1 == initial_tab_count); | 250 ASSERT_TRUE(1 == initial_tab_count); |
| 250 | 251 |
| (...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 482 scoped_refptr<TabProxy> tab1_2(browser2->GetTab(0)); | 483 scoped_refptr<TabProxy> tab1_2(browser2->GetTab(0)); |
| 483 ASSERT_TRUE(tab1_2.get()); | 484 ASSERT_TRUE(tab1_2.get()); |
| 484 GURL tab1_2_url; | 485 GURL tab1_2_url; |
| 485 ASSERT_TRUE(tab1_2->GetCurrentURL(&tab1_2_url)); | 486 ASSERT_TRUE(tab1_2->GetCurrentURL(&tab1_2_url)); |
| 486 | 487 |
| 487 // Tab_1_2 of Window 2 should essentially be Tab_2 of Window 1. | 488 // Tab_1_2 of Window 2 should essentially be Tab_2 of Window 1. |
| 488 EXPECT_EQ(tab1_2_url.spec(), tab2_url.spec()); | 489 EXPECT_EQ(tab1_2_url.spec(), tab2_url.spec()); |
| 489 EXPECT_NE(tab1_2_url.spec(), tab1_url.spec()); | 490 EXPECT_NE(tab1_2_url.spec(), tab1_url.spec()); |
| 490 EXPECT_NE(tab1_2_url.spec(), tab3_url.spec()); | 491 EXPECT_NE(tab1_2_url.spec(), tab3_url.spec()); |
| 491 } | 492 } |
| OLD | NEW |