Revert "Make renderer-initiated navigation to about:blank to use the default path."

This reverts commit ef860d19967a2ec89c01b5a9c08e9aea8881e125. Not everything is
reverted, all the previously updated tests stays the same.

Reason for revert:
Successive navigations to about:blank triggered from the same script execution
used to be collapsed into one. By using the default code path without
PerNavigationMojoInterface, all of them commit successfully. I am reverting this
patch to preserve the old behavior and will be able to reland it later.

Original message description:

Make renderer-initiated navigation to about:blank to use the default path.

We used to believe renderer initiated navigation from a document to
about:blank needed to happen sometimes "synchronously". This isn't the
case, a PostTask is currently used. The only real requirement is when
committing the initial empty document.

This CL makes those navigation to use the default path instead.

This requires a few tests to be updated:

1) The initiator and a few other properties needs to be properly set. There
   are DCHECK in BeginNavigationInternal to enforce renderer initiated
   navigation always have a defined initiator.

2) runtime-console-log-handle-navigate.js: In console-log-navigate, console.log
   can use the 'getter' of the object several times (up to 2) to print the
   object. It triggers several about:blank navigations. Since they are now going
   to the browser process, they are committed later compared to the script
   execution. The test became less reliable. The test was using
   dp.Runtime.onceExecutionContextCreated to wait for new documents to commit,
   but waiting was started potentially after the event occured. The new test is
   now creating the Promise before triggering the action that will later resolve
   it. The action is either creating the iframe or making use of the logXXX()
   function. This is now fully reliable.

Bug: 936696, 965410
Change-Id: Ib4e514f9e1c8f70b8329f961b23f381302840e84
Reviewed-by: Camille Lamy <>
Reviewed-by: Arthur Sonzogni <>
Commit-Queue: Arthur Sonzogni <>
Cr-Commit-Position: refs/heads/master@{#662655}
3 files changed