Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(161)

Unified Diff: ios/web/web_state/web_state_impl_unittest.mm

Issue 2711363003: Use DidFinishNavigation callback in LanguageDetectionController. (Closed)
Patch Set: Removed unused method Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ios/web/web_state/web_state_impl.mm ('k') | ios/web/web_state/web_state_observer_bridge.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/web/web_state/web_state_impl_unittest.mm
diff --git a/ios/web/web_state/web_state_impl_unittest.mm b/ios/web/web_state/web_state_impl_unittest.mm
index 992132f9f2dbc2eb5afb9ca6c315292d65e3df37..3aa7097011a1b22d10224c578d8cef5c0de1a014 100644
--- a/ios/web/web_state/web_state_impl_unittest.mm
+++ b/ios/web/web_state/web_state_impl_unittest.mm
@@ -127,7 +127,6 @@ class TestWebStateObserver : public WebStateObserver {
navigation_item_changed_called_(false),
navigation_item_committed_called_(false),
page_loaded_called_with_success_(false),
- url_hash_changed_called_(false),
history_state_changed_called_(false),
did_finish_navigation_called_(false),
web_state_destroyed_called_(false) {}
@@ -149,7 +148,6 @@ class TestWebStateObserver : public WebStateObserver {
bool page_loaded_called_with_success() const {
return page_loaded_called_with_success_;
}
- bool url_hash_changed_called() const { return url_hash_changed_called_; }
bool history_state_changed_called() const {
return history_state_changed_called_;
}
@@ -182,8 +180,6 @@ class TestWebStateObserver : public WebStateObserver {
page_loaded_called_with_success_ =
load_completion_status == PageLoadCompletionStatus::SUCCESS;
}
- void UrlHashChanged() override { url_hash_changed_called_ = true; }
- void HistoryStateChanged() override { history_state_changed_called_ = true; }
void WebStateDestroyed() override {
EXPECT_TRUE(web_state()->IsBeingDestroyed());
web_state_destroyed_called_ = true;
@@ -195,7 +191,6 @@ class TestWebStateObserver : public WebStateObserver {
bool navigation_item_changed_called_;
bool navigation_item_committed_called_;
bool page_loaded_called_with_success_;
- bool url_hash_changed_called_;
bool history_state_changed_called_;
bool did_finish_navigation_called_;
bool web_state_destroyed_called_;
@@ -392,16 +387,6 @@ TEST_F(WebStateTest, ObserverTest) {
web_state_->OnPageLoaded(GURL("http://test"), true);
EXPECT_TRUE(observer->page_loaded_called_with_success());
- // Test that UrlHashChanged() is called.
- EXPECT_FALSE(observer->url_hash_changed_called());
- web_state_->OnUrlHashChanged();
- EXPECT_TRUE(observer->url_hash_changed_called());
-
- // Test that HistoryStateChanged() is called.
- EXPECT_FALSE(observer->history_state_changed_called());
- web_state_->OnHistoryStateChanged();
- EXPECT_TRUE(observer->history_state_changed_called());
-
// Test that DidFinishNavigation() is called for same page navigations.
EXPECT_FALSE(observer->did_finish_navigation_called());
web_state_->OnSamePageNavigation(GURL("http://test"));
« no previous file with comments | « ios/web/web_state/web_state_impl.mm ('k') | ios/web/web_state/web_state_observer_bridge.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698