scheduler: Always create a real scheduler in unit tests
Previously we would create a dummy scheduler in any test which uses
TestBlinkWebUnitTestSupport without first initializing a message loop.
This causes problems because the dummy scheduler ignores all tasks it
is given.
This patch makes the tests more realistic by always creating a real
renderer scheduler regardless of whether we have a message loop or not.
This is achieved by lazily binding the scheduler to the message loop
the first time it is needed.
Longer term we would like to refactor these test suites to ensure Blink
always has a valid message loop when it is initialized, but this will
involve rewiring several tests.
BUG=463143,495659
Committed: https://crrev.com/
087644f1eab41927823a1a2fc2df08bd4e10fe18
Cr-Commit-Position: refs/heads/master@{#332685}
Review URL: https://codereview.chromium.org/
1152623008
Cr-Commit-Position: refs/heads/master@{#332818}