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

Unified Diff: ios/chrome/browser/sessions/session_window_unittest.mm

Issue 2720613005: Refactor serialisation of openerId & openerNavigationIndex. (Closed)
Patch Set: Fix CRWSessionController's initializer comment. 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
Index: ios/chrome/browser/sessions/session_window_unittest.mm
diff --git a/ios/chrome/browser/sessions/session_window_unittest.mm b/ios/chrome/browser/sessions/session_window_unittest.mm
index 8f9d4fdc1a4e850229a59bd6b236476b8afd9923..52101b1706e5203e8828e6c61ed61621b7165d67 100644
--- a/ios/chrome/browser/sessions/session_window_unittest.mm
+++ b/ios/chrome/browser/sessions/session_window_unittest.mm
@@ -44,8 +44,8 @@ class SessionWindowIOSTest : public PlatformTest {
NSString* opener,
BOOL openedByDOM) const {
WebStateImpl* webState = new WebStateImpl(chrome_browser_state_.get());
- webState->GetNavigationManagerImpl().InitializeSession(window_name, opener,
- openedByDOM, 0);
+ webState->GetNavigationManagerImpl().InitializeSession(window_name,
+ openedByDOM);
return webState;
}
@@ -84,11 +84,7 @@ TEST_F(SessionWindowIOSTest, CodingEncoding) {
std::unique_ptr<WebStateImpl> webState1(
CreateWebState(windowName1, nil, YES));
- NSString* openerId1 =
- webState1->GetNavigationManagerImpl().GetSessionController().openerId;
std::unique_ptr<WebStateImpl> webState2(CreateWebState(windowName2, nil, NO));
- NSString* openerId2 =
- webState2->GetNavigationManagerImpl().GetSessionController().openerId;
[sessionWindow addSerializedSessionStorage:webState1->BuildSessionStorage()];
[sessionWindow addSerializedSessionStorage:webState2->BuildSessionStorage()];
@@ -107,12 +103,10 @@ TEST_F(SessionWindowIOSTest, CodingEncoding) {
ASSERT_EQ(2U, sessions.count);
CRWSessionStorage* unarchivedSession1 = sessions[0];
EXPECT_NSEQ(windowName1, unarchivedSession1.windowName);
- EXPECT_NSEQ(openerId1, unarchivedSession1.openerID);
EXPECT_TRUE(unarchivedSession1.openedByDOM);
CRWSessionStorage* unarchivedSession2 = sessions[1];
EXPECT_NSEQ(windowName2, unarchivedSession2.windowName);
- EXPECT_NSEQ(openerId2, unarchivedSession2.openerID);
EXPECT_FALSE(unarchivedSession2.openedByDOM);
}
« no previous file with comments | « ios/chrome/browser/native_app_launcher/native_app_navigation_util_unittest.mm ('k') | ios/chrome/browser/tabs/tab.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698