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

Unified Diff: content/common/page_state_serialization_unittest.cc

Issue 51423002: Add a target_frame_id to the history serialization format. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Unconditionlly setTargetFrameID() Created 7 years, 2 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 | « content/common/page_state_serialization.cc ('k') | content/public/renderer/history_item_serialization.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/page_state_serialization_unittest.cc
diff --git a/content/common/page_state_serialization_unittest.cc b/content/common/page_state_serialization_unittest.cc
index d53300f0fd695181cdf0558caf371bacd86a802f..5b79c96e8ca94c542ce6a6c73ddfb89ab63b83d5 100644
--- a/content/common/page_state_serialization_unittest.cc
+++ b/content/common/page_state_serialization_unittest.cc
@@ -75,6 +75,7 @@ void ExpectEquality(const ExplodedFrameState& a, const ExplodedFrameState& b) {
EXPECT_EQ(a.scroll_offset, b.scroll_offset);
EXPECT_EQ(a.item_sequence_number, b.item_sequence_number);
EXPECT_EQ(a.document_sequence_number, b.document_sequence_number);
+ EXPECT_EQ(a.target_frame_id, b.target_frame_id);
EXPECT_EQ(a.page_scale_factor, b.page_scale_factor);
ExpectEquality(a.http_body, b.http_body);
ExpectEquality(a.children, b.children);
@@ -103,6 +104,7 @@ class PageStateSerializationTest : public testing::Test {
frame_state->scroll_offset = gfx::Point(0, 100);
frame_state->item_sequence_number = 1;
frame_state->document_sequence_number = 2;
+ frame_state->target_frame_id = 3;
frame_state->page_scale_factor = 2.0;
}
@@ -140,6 +142,7 @@ class PageStateSerializationTest : public testing::Test {
frame_state->scroll_offset = gfx::Point(42, -42);
frame_state->item_sequence_number = 123;
frame_state->document_sequence_number = 456;
+ frame_state->target_frame_id = 0;
frame_state->page_scale_factor = 2.0f;
frame_state->document_state.push_back(
@@ -414,5 +417,9 @@ TEST_F(PageStateSerializationTest, BackwardsCompat_v15) {
TestBackwardsCompat(15);
}
+TEST_F(PageStateSerializationTest, BackwardsCompat_v16) {
+ TestBackwardsCompat(16);
+}
+
} // namespace
} // namespace content
« no previous file with comments | « content/common/page_state_serialization.cc ('k') | content/public/renderer/history_item_serialization.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698