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

Unified Diff: chrome/browser/policy/configuration_policy_provider_test.cc

Issue 11413050: chrome/browser: Update calls from RunAllPending() to RunUntilIdle(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/policy/configuration_policy_provider_test.cc
diff --git a/chrome/browser/policy/configuration_policy_provider_test.cc b/chrome/browser/policy/configuration_policy_provider_test.cc
index 2d0ac93dba7180e2a21d8798e1001d64ea9c47f4..6631dd0e8bb041c03e0bd9a27c98f40787380795 100644
--- a/chrome/browser/policy/configuration_policy_provider_test.cc
+++ b/chrome/browser/policy/configuration_policy_provider_test.cc
@@ -49,7 +49,7 @@ PolicyTestBase::PolicyTestBase()
PolicyTestBase::~PolicyTestBase() {}
void PolicyTestBase::TearDown() {
- loop_.RunAllPending();
+ loop_.RunUntilIdle();
}
PolicyProviderTestHarness::PolicyProviderTestHarness(PolicyLevel level,
@@ -86,7 +86,7 @@ void ConfigurationPolicyProviderTest::SetUp() {
provider_->Init();
// Some providers do a reload on init. Make sure any notifications generated
// are fired now.
- loop_.RunAllPending();
+ loop_.RunUntilIdle();
const PolicyBundle kEmptyBundle;
EXPECT_TRUE(provider_->policies().Equals(kEmptyBundle));
@@ -107,7 +107,7 @@ void ConfigurationPolicyProviderTest::CheckValue(
// Install the value, reload policy and check the provider for the value.
install_value.Run();
provider_->RefreshPolicies();
- loop_.RunAllPending();
+ loop_.RunUntilIdle();
PolicyBundle expected_bundle;
expected_bundle.Get(POLICY_DOMAIN_CHROME, "")
.Set(policy_name,
@@ -121,7 +121,7 @@ void ConfigurationPolicyProviderTest::CheckValue(
TEST_P(ConfigurationPolicyProviderTest, Empty) {
provider_->RefreshPolicies();
- loop_.RunAllPending();
+ loop_.RunUntilIdle();
const PolicyBundle kEmptyBundle;
EXPECT_TRUE(provider_->policies().Equals(kEmptyBundle));
}
@@ -211,7 +211,7 @@ TEST_P(ConfigurationPolicyProviderTest, RefreshPolicies) {
provider_->AddObserver(&observer);
EXPECT_CALL(observer, OnUpdatePolicy(provider_.get())).Times(1);
provider_->RefreshPolicies();
- loop_.RunAllPending();
+ loop_.RunUntilIdle();
Mock::VerifyAndClearExpectations(&observer);
EXPECT_TRUE(provider_->policies().Equals(bundle));
@@ -221,7 +221,7 @@ TEST_P(ConfigurationPolicyProviderTest, RefreshPolicies) {
"value");
EXPECT_CALL(observer, OnUpdatePolicy(provider_.get())).Times(1);
provider_->RefreshPolicies();
- loop_.RunAllPending();
+ loop_.RunUntilIdle();
Mock::VerifyAndClearExpectations(&observer);
bundle.Get(POLICY_DOMAIN_CHROME, "")
@@ -305,7 +305,7 @@ TEST_P(Configuration3rdPartyPolicyProviderTest, Load3rdParty) {
test_harness_->Install3rdPartyPolicy(&policy_3rdparty);
provider_->RefreshPolicies();
- loop_.RunAllPending();
+ loop_.RunUntilIdle();
PolicyMap expected_policy;
expected_policy.Set(test_policy_definitions::kKeyDictionary,
« no previous file with comments | « chrome/browser/policy/cloud_policy_validator_unittest.cc ('k') | chrome/browser/policy/cros_user_policy_cache_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698