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

Unified Diff: chrome/browser/sync/test/integration/autofill_helper.cc

Issue 10855253: Convert the autofill pyauto tests to browser tests, and remove all the supporting automation hooks … (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: review comments Created 8 years, 4 months 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/sync/test/integration/autofill_helper.cc
===================================================================
--- chrome/browser/sync/test/integration/autofill_helper.cc (revision 152427)
+++ chrome/browser/sync/test/integration/autofill_helper.cc (working copy)
@@ -221,6 +221,17 @@
pdm->RemoveObserver(&observer);
}
+void SetCreditCards(int profile, std::vector<CreditCard>* credit_cards) {
+ MockPersonalDataManagerObserver observer;
+ EXPECT_CALL(observer, OnPersonalDataChanged()).
+ WillOnce(QuitUIMessageLoop());
+ PersonalDataManager* pdm = GetPersonalDataManager(profile);
+ pdm->SetObserver(&observer);
+ pdm->SetCreditCards(credit_cards);
+ MessageLoop::current()->Run();
+ pdm->RemoveObserver(&observer);
+}
+
void AddProfile(int profile, const AutofillProfile& autofill_profile) {
const std::vector<AutofillProfile*>& all_profiles = GetAllProfiles(profile);
std::vector<AutofillProfile> autofill_profiles;

Powered by Google App Engine
This is Rietveld 408576698