| 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 "base/basictypes.h" | 5 #include "base/basictypes.h" |
| 6 #include "base/command_line.h" | 6 #include "base/command_line.h" |
| 7 #include "base/files/file_path.h" | 7 #include "base/files/file_path.h" |
| 8 #include "base/test/test_timeouts.h" | 8 #include "base/test/test_timeouts.h" |
| 9 #include "base/utf_string_conversions.h" | 9 #include "base/utf_string_conversions.h" |
| 10 #include "chrome/app/chrome_command_ids.h" | 10 #include "chrome/app/chrome_command_ids.h" |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 #include "chrome/test/base/ui_test_utils.h" | 21 #include "chrome/test/base/ui_test_utils.h" |
| 22 #include "content/public/browser/navigation_controller.h" | 22 #include "content/public/browser/navigation_controller.h" |
| 23 #include "content/public/browser/notification_service.h" | 23 #include "content/public/browser/notification_service.h" |
| 24 #include "content/public/browser/notification_source.h" | 24 #include "content/public/browser/notification_source.h" |
| 25 #include "content/public/browser/notification_types.h" | 25 #include "content/public/browser/notification_types.h" |
| 26 #include "content/public/browser/page_navigator.h" | 26 #include "content/public/browser/page_navigator.h" |
| 27 #include "content/public/browser/render_view_host.h" | 27 #include "content/public/browser/render_view_host.h" |
| 28 #include "content/public/browser/web_contents.h" | 28 #include "content/public/browser/web_contents.h" |
| 29 #include "googleurl/src/gurl.h" | 29 #include "googleurl/src/gurl.h" |
| 30 #include "net/base/net_util.h" | 30 #include "net/base/net_util.h" |
| 31 #include "net/test/spawned_test_server.h" | 31 #include "net/test/spawned_test_server/spawned_test_server.h" |
| 32 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFindOptions.h" | 32 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFindOptions.h" |
| 33 | 33 |
| 34 class TabRestoreTest : public InProcessBrowserTest { | 34 class TabRestoreTest : public InProcessBrowserTest { |
| 35 public: | 35 public: |
| 36 TabRestoreTest() | 36 TabRestoreTest() |
| 37 : native_browser_list(BrowserList::GetInstance( | 37 : native_browser_list(BrowserList::GetInstance( |
| 38 chrome::HOST_DESKTOP_TYPE_NATIVE)) { | 38 chrome::HOST_DESKTOP_TYPE_NATIVE)) { |
| 39 url1_ = ui_test_utils::GetTestUrl( | 39 url1_ = ui_test_utils::GetTestUrl( |
| 40 base::FilePath().AppendASCII("session_history"), | 40 base::FilePath().AppendASCII("session_history"), |
| 41 base::FilePath().AppendASCII("bot1.html")); | 41 base::FilePath().AppendASCII("bot1.html")); |
| (...skipping 524 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 566 EnsureTabFinishedRestoring(tab); | 566 EnsureTabFinishedRestoring(tab); |
| 567 ASSERT_EQ(http_url, tab->GetURL()); | 567 ASSERT_EQ(http_url, tab->GetURL()); |
| 568 | 568 |
| 569 // Go back, and see if content is as expected. | 569 // Go back, and see if content is as expected. |
| 570 GoBack(browser()); | 570 GoBack(browser()); |
| 571 EXPECT_GT( | 571 EXPECT_GT( |
| 572 ui_test_utils::FindInPage(tab, ASCIIToUTF16("webkit"), true, false, NULL, | 572 ui_test_utils::FindInPage(tab, ASCIIToUTF16("webkit"), true, false, NULL, |
| 573 NULL), | 573 NULL), |
| 574 0); | 574 0); |
| 575 } | 575 } |
| OLD | NEW |