Commit d9beaa22 authored by Dominique Fauteux-Chapleau's avatar Dominique Fauteux-Chapleau Committed by Commit Bot

Fixes ExternalProviderImplTest test

NoBlockedExternalUserProviders is now flaky because it used to use
MessageLoopRunner (which uses a deferred Quit) and was refactored
to use RunLoop.QuitClosure (which doesn't use a deferred Quit).
This fix keeps RunLoop but uses QuitWhenIdleClosure instead of
QuitClosure.

Bug: 1019160
Change-Id: I9061165ac4e6f959cef1b8a4cb7565dd52f35974
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1887051Reviewed-by: default avatarDevlin <rdevlin.cronin@chromium.org>
Commit-Queue: Dominique Fauteux-Chapleau <domfc@chromium.org>
Cr-Commit-Position: refs/heads/master@{#710802}
parent 063ea76b
......@@ -185,7 +185,7 @@ TEST_F(ExternalProviderImplTest, InAppPayments) {
base::RunLoop run_loop;
service_->set_external_updates_finished_callback_for_test(
run_loop.QuitClosure());
run_loop.QuitWhenIdleClosure());
service_->CheckForExternalUpdates();
run_loop.Run();
......@@ -201,7 +201,7 @@ TEST_F(ExternalProviderImplTest, BlockedExternalUserProviders) {
base::RunLoop run_loop;
service_->set_external_updates_finished_callback_for_test(
run_loop.QuitClosure());
run_loop.QuitWhenIdleClosure());
service_->CheckForExternalUpdates();
run_loop.Run();
......@@ -214,7 +214,7 @@ TEST_F(ExternalProviderImplTest, NotBlockedExternalUserProviders) {
base::RunLoop run_loop;
service_->set_external_updates_finished_callback_for_test(
run_loop.QuitClosure());
run_loop.QuitWhenIdleClosure());
service_->CheckForExternalUpdates();
run_loop.Run();
......
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