| Index: content/browser/frame_host/navigation_controller_impl_unittest.cc
|
| diff --git a/content/browser/frame_host/navigation_controller_impl_unittest.cc b/content/browser/frame_host/navigation_controller_impl_unittest.cc
|
| index b23fb0156a37669669e0312f395f165c16ec67d5..8eccc89d3b4d6b8480947cb98a7baf48a909daac 100644
|
| --- a/content/browser/frame_host/navigation_controller_impl_unittest.cc
|
| +++ b/content/browser/frame_host/navigation_controller_impl_unittest.cc
|
| @@ -307,13 +307,13 @@ class LoadCommittedDetailsObserver : public WebContentsObserver {
|
| explicit LoadCommittedDetailsObserver(WebContents* web_contents)
|
| : WebContentsObserver(web_contents),
|
| navigation_type_(NAVIGATION_TYPE_UNKNOWN),
|
| - is_in_page_(false),
|
| + is_same_document_(false),
|
| is_main_frame_(false),
|
| did_replace_entry_(false) {}
|
|
|
| NavigationType navigation_type() { return navigation_type_; }
|
| const GURL& previous_url() { return previous_url_; }
|
| - bool is_in_page() { return is_in_page_; }
|
| + bool is_same_document() { return is_same_document_; }
|
| bool is_main_frame() { return is_main_frame_; }
|
| bool did_replace_entry() { return did_replace_entry_; }
|
|
|
| @@ -325,14 +325,14 @@ class LoadCommittedDetailsObserver : public WebContentsObserver {
|
| navigation_type_ = static_cast<NavigationHandleImpl*>(navigation_handle)
|
| ->navigation_type();
|
| previous_url_ = navigation_handle->GetPreviousURL();
|
| - is_in_page_ = navigation_handle->IsSameDocument();
|
| + is_same_document_ = navigation_handle->IsSameDocument();
|
| is_main_frame_ = navigation_handle->IsInMainFrame();
|
| did_replace_entry_ = navigation_handle->DidReplaceEntry();
|
| }
|
|
|
| NavigationType navigation_type_;
|
| GURL previous_url_;
|
| - bool is_in_page_;
|
| + bool is_same_document_;
|
| bool is_main_frame_;
|
| bool did_replace_entry_;
|
| };
|
| @@ -2275,7 +2275,7 @@ TEST_F(NavigationControllerTest, NewSubframe) {
|
| EXPECT_EQ(1U, navigation_entry_committed_counter_);
|
| navigation_entry_committed_counter_ = 0;
|
| EXPECT_EQ(url1, observer.previous_url());
|
| - EXPECT_FALSE(observer.is_in_page());
|
| + EXPECT_FALSE(observer.is_same_document());
|
| EXPECT_FALSE(observer.is_main_frame());
|
|
|
| // The new entry should be appended.
|
| @@ -2656,7 +2656,7 @@ TEST_F(NavigationControllerTest, InPage) {
|
| NavigationEntry* entry1 = controller.GetLastCommittedEntry();
|
| EXPECT_EQ(1U, navigation_entry_committed_counter_);
|
| navigation_entry_committed_counter_ = 0;
|
| - EXPECT_TRUE(observer.is_in_page());
|
| + EXPECT_TRUE(observer.is_same_document());
|
| EXPECT_TRUE(observer.did_replace_entry());
|
| EXPECT_EQ(1, controller.GetEntryCount());
|
|
|
| @@ -2681,7 +2681,7 @@ TEST_F(NavigationControllerTest, InPage) {
|
| NavigationEntry* entry2 = controller.GetLastCommittedEntry();
|
| EXPECT_EQ(1U, navigation_entry_committed_counter_);
|
| navigation_entry_committed_counter_ = 0;
|
| - EXPECT_TRUE(observer.is_in_page());
|
| + EXPECT_TRUE(observer.is_same_document());
|
| EXPECT_FALSE(observer.did_replace_entry());
|
| EXPECT_EQ(2, controller.GetEntryCount());
|
|
|
| @@ -2693,7 +2693,7 @@ TEST_F(NavigationControllerTest, InPage) {
|
| main_test_rfh()->SendNavigateWithParams(&back_params);
|
| EXPECT_EQ(1U, navigation_entry_committed_counter_);
|
| navigation_entry_committed_counter_ = 0;
|
| - EXPECT_TRUE(observer.is_in_page());
|
| + EXPECT_TRUE(observer.is_same_document());
|
| EXPECT_EQ(2, controller.GetEntryCount());
|
| EXPECT_EQ(0, controller.GetCurrentEntryIndex());
|
| EXPECT_EQ(back_params.url, controller.GetVisibleEntry()->GetURL());
|
| @@ -2706,7 +2706,7 @@ TEST_F(NavigationControllerTest, InPage) {
|
| main_test_rfh()->SendNavigateWithParams(&forward_params);
|
| EXPECT_EQ(1U, navigation_entry_committed_counter_);
|
| navigation_entry_committed_counter_ = 0;
|
| - EXPECT_TRUE(observer.is_in_page());
|
| + EXPECT_TRUE(observer.is_same_document());
|
| EXPECT_EQ(2, controller.GetEntryCount());
|
| EXPECT_EQ(1, controller.GetCurrentEntryIndex());
|
| EXPECT_EQ(forward_params.url,
|
| @@ -2738,7 +2738,7 @@ TEST_F(NavigationControllerTest, InPage) {
|
| main_test_rfh()->SendNavigateWithParams(¶ms);
|
| EXPECT_EQ(1U, navigation_entry_committed_counter_);
|
| navigation_entry_committed_counter_ = 0;
|
| - EXPECT_FALSE(observer.is_in_page());
|
| + EXPECT_FALSE(observer.is_same_document());
|
| EXPECT_EQ(3, controller.GetEntryCount());
|
| EXPECT_EQ(2, controller.GetCurrentEntryIndex());
|
| }
|
| @@ -2772,7 +2772,7 @@ TEST_F(NavigationControllerTest, InPage_Replace) {
|
| main_test_rfh()->SendNavigateWithParams(¶ms);
|
| EXPECT_EQ(1U, navigation_entry_committed_counter_);
|
| navigation_entry_committed_counter_ = 0;
|
| - EXPECT_TRUE(observer.is_in_page());
|
| + EXPECT_TRUE(observer.is_same_document());
|
| EXPECT_TRUE(observer.did_replace_entry());
|
| EXPECT_EQ(1, controller.GetEntryCount());
|
| }
|
| @@ -2824,7 +2824,7 @@ TEST_F(NavigationControllerTest, ClientRedirectAfterInPageNavigation) {
|
| main_test_rfh()->SendNavigateWithParams(¶ms);
|
| EXPECT_EQ(1U, navigation_entry_committed_counter_);
|
| navigation_entry_committed_counter_ = 0;
|
| - EXPECT_TRUE(observer.is_in_page());
|
| + EXPECT_TRUE(observer.is_same_document());
|
| EXPECT_TRUE(observer.did_replace_entry());
|
| EXPECT_EQ(2, controller.GetEntryCount());
|
| }
|
| @@ -2851,7 +2851,7 @@ TEST_F(NavigationControllerTest, ClientRedirectAfterInPageNavigation) {
|
| main_test_rfh()->SendNavigateWithParams(¶ms);
|
| EXPECT_EQ(1U, navigation_entry_committed_counter_);
|
| navigation_entry_committed_counter_ = 0;
|
| - EXPECT_FALSE(observer.is_in_page());
|
| + EXPECT_FALSE(observer.is_same_document());
|
| EXPECT_EQ(3, controller.GetEntryCount());
|
| }
|
|
|
| @@ -5140,7 +5140,7 @@ TEST_F(NavigationControllerTest, UnreachableURLGivesErrorPage) {
|
| main_test_rfh()->SendNavigateWithParams(¶ms);
|
| EXPECT_EQ(PAGE_TYPE_ERROR,
|
| controller_impl().GetLastCommittedEntry()->GetPageType());
|
| - EXPECT_TRUE(observer.is_in_page());
|
| + EXPECT_TRUE(observer.is_same_document());
|
| }
|
| }
|
|
|
|
|