Commit 3d5801a9 authored by Tarun Bansal's avatar Tarun Bansal Committed by Commit Bot

Fix resource loading hints flaky test

Make the test wait for resource loading hints to be available.

Change-Id: I4b0cd3d3f03c53efcd386f16c6e70d05d9ef2ed4
Bug: 863250
Reviewed-on: https://chromium-review.googlesource.com/1136838Reviewed-by: default avatarRyan Sturm <ryansturm@chromium.org>
Commit-Queue: Tarun Bansal <tbansal@chromium.org>
Cr-Commit-Position: refs/heads/master@{#575011}
parent 2a7176cb
......@@ -280,6 +280,12 @@ IN_PROC_BROWSER_TEST_F(
IN_PROC_BROWSER_TEST_F(ResourceLoadingHintsBrowserTest,
ResourceLoadingHintsHttpsNoWhitelisted) {
TestOptimizationGuideServiceObserver observer;
AddTestOptimizationGuideServiceObserver(&observer);
base::RunLoop().RunUntilIdle();
SetResourceLoadingHintsWhitelist({});
observer.WaitForNotification();
base::HistogramTester histogram_tester;
// The URL is not whitelisted.
ui_test_utils::NavigateToURL(browser(), https_url());
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment