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

Issue 2309583002: Fix for the NavigationControllerTest.BackSubframe test failures with PlzNavigate (Closed)

Created:
4 years, 3 months ago by ananta
Modified:
4 years, 3 months ago
Reviewers:
clamy, nasko
CC:
chromium-reviews, jam, nasko+codewatch_chromium.org, darin-cc_chromium.org, creis+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Fix for the NavigationControllerTest.BackSubframe test failures with PlzNavigate The test was crashing in the controller.GoBack() case with PlzNavigate enabled. Reason being we don't find a frame to navigate to. Thanks to clamy for pointing out that the sequence numbers setting code in the frame navigation code caused that. Fix is to add the item sequence number and document sequence number to the page state. Added a helper function to the TestRenderFrameHost class called CreatePageStateForURL which provides this functionality. BUG=510836 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_site_isolation Committed: https://crrev.com/7cf627a6bd6704018b6f2091c176d4762f080797 Cr-Commit-Position: refs/heads/master@{#417165}

Patch Set 1 #

Total comments: 2

Patch Set 2 : Honor the item_sequence_number_ and document_sequence_number_ fields in the FrameNavigationEntry cl… #

Patch Set 3 : Fix code #

Total comments: 2

Patch Set 4 : Add the item sequence number and document sequence number to the page state #

Total comments: 6

Patch Set 5 : Address review comments #

Patch Set 6 : Revert changes to test_render_frame_host #

Patch Set 7 : Revert changes to test_render_frame_host.cc #

Total comments: 4

Patch Set 8 : Set document_sequence_number correctly and use the same strategy like Blink to generate these numbe… #

Unified diffs Side-by-side diffs Delta from patch set Stats (+50 lines, -8 lines) Patch
M content/browser/frame_host/navigation_controller_impl_unittest.cc View 1 2 3 4 5 6 7 8 chunks +28 lines, -8 lines 0 comments Download
M content/public/common/page_state.h View 1 2 3 4 1 chunk +7 lines, -0 lines 0 comments Download
M content/public/common/page_state.cc View 1 2 3 4 1 chunk +15 lines, -0 lines 0 comments Download

Messages

Total messages: 43 (29 generated)
ananta
4 years, 3 months ago (2016-09-03 00:50:51 UTC) #3
clamy
Thanks! As explained in the comment, I don't think the fix is the right one ...
4 years, 3 months ago (2016-09-06 12:32:08 UTC) #8
ananta
https://codereview.chromium.org/2309583002/diff/1/content/browser/frame_host/navigation_controller_impl_unittest.cc File content/browser/frame_host/navigation_controller_impl_unittest.cc (right): https://codereview.chromium.org/2309583002/diff/1/content/browser/frame_host/navigation_controller_impl_unittest.cc#newcode2572 content/browser/frame_host/navigation_controller_impl_unittest.cc:2572: subframe->PrepareForCommitIfNecessary(); On 2016/09/06 12:32:08, clamy wrote: > This test ...
4 years, 3 months ago (2016-09-07 02:43:37 UTC) #9
clamy
@nasko: could you take a look at this one since it modifies code introduced by ...
4 years, 3 months ago (2016-09-07 14:22:41 UTC) #18
nasko
https://codereview.chromium.org/2309583002/diff/40001/content/browser/frame_host/frame_navigation_entry.cc File content/browser/frame_host/frame_navigation_entry.cc (right): https://codereview.chromium.org/2309583002/diff/40001/content/browser/frame_host/frame_navigation_entry.cc#newcode96 content/browser/frame_host/frame_navigation_entry.cc:96: if (exploded_state.top.item_sequence_number > 0 || I don't think this ...
4 years, 3 months ago (2016-09-07 20:56:02 UTC) #19
nasko
On 2016/09/07 14:22:41, clamy wrote: > @nasko: could you take a look at this one ...
4 years, 3 months ago (2016-09-07 20:57:07 UTC) #20
ananta
https://codereview.chromium.org/2309583002/diff/40001/content/browser/frame_host/frame_navigation_entry.cc File content/browser/frame_host/frame_navigation_entry.cc (right): https://codereview.chromium.org/2309583002/diff/40001/content/browser/frame_host/frame_navigation_entry.cc#newcode96 content/browser/frame_host/frame_navigation_entry.cc:96: if (exploded_state.top.item_sequence_number > 0 || On 2016/09/07 20:56:02, nasko ...
4 years, 3 months ago (2016-09-07 22:50:07 UTC) #22
nasko
Thanks, this is much better direction! https://codereview.chromium.org/2309583002/diff/60001/content/browser/frame_host/navigation_controller_impl_unittest.cc File content/browser/frame_host/navigation_controller_impl_unittest.cc (right): https://codereview.chromium.org/2309583002/diff/60001/content/browser/frame_host/navigation_controller_impl_unittest.cc#newcode2506 content/browser/frame_host/navigation_controller_impl_unittest.cc:2506: url2, item_sequence_number2, 0); ...
4 years, 3 months ago (2016-09-07 23:21:59 UTC) #25
ananta
https://codereview.chromium.org/2309583002/diff/60001/content/browser/frame_host/navigation_controller_impl_unittest.cc File content/browser/frame_host/navigation_controller_impl_unittest.cc (right): https://codereview.chromium.org/2309583002/diff/60001/content/browser/frame_host/navigation_controller_impl_unittest.cc#newcode2506 content/browser/frame_host/navigation_controller_impl_unittest.cc:2506: url2, item_sequence_number2, 0); On 2016/09/07 23:21:59, nasko (slow) wrote: ...
4 years, 3 months ago (2016-09-07 23:58:44 UTC) #26
nasko
LGTM with a couple of nits addressed. Thanks! https://codereview.chromium.org/2309583002/diff/120001/content/browser/frame_host/navigation_controller_impl_unittest.cc File content/browser/frame_host/navigation_controller_impl_unittest.cc (right): https://codereview.chromium.org/2309583002/diff/120001/content/browser/frame_host/navigation_controller_impl_unittest.cc#newcode2463 content/browser/frame_host/navigation_controller_impl_unittest.cc:2463: int64_t ...
4 years, 3 months ago (2016-09-08 00:19:00 UTC) #31
ananta
https://codereview.chromium.org/2309583002/diff/120001/content/browser/frame_host/navigation_controller_impl_unittest.cc File content/browser/frame_host/navigation_controller_impl_unittest.cc (right): https://codereview.chromium.org/2309583002/diff/120001/content/browser/frame_host/navigation_controller_impl_unittest.cc#newcode2463 content/browser/frame_host/navigation_controller_impl_unittest.cc:2463: int64_t document_sequence_number1 = base::Time::Now().ToDoubleT() * 1000000; On 2016/09/08 00:18:59, ...
4 years, 3 months ago (2016-09-08 00:41:39 UTC) #32
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2309583002/140001
4 years, 3 months ago (2016-09-08 02:13:10 UTC) #39
commit-bot: I haz the power
Committed patchset #8 (id:140001)
4 years, 3 months ago (2016-09-08 02:17:12 UTC) #41
commit-bot: I haz the power
4 years, 3 months ago (2016-09-08 02:19:28 UTC) #43
Message was sent while issue was closed.
Patchset 8 (id:??) landed as
https://crrev.com/7cf627a6bd6704018b6f2091c176d4762f080797
Cr-Commit-Position: refs/heads/master@{#417165}

Powered by Google App Engine
This is Rietveld 408576698