Chromium Code Reviews| Index: chrome/browser/autofill/personal_data_manager_unittest.cc |
| =================================================================== |
| --- chrome/browser/autofill/personal_data_manager_unittest.cc (revision 72012) |
| +++ chrome/browser/autofill/personal_data_manager_unittest.cc (working copy) |
| @@ -278,6 +278,9 @@ |
| EXPECT_EQ(creditcard0, *results2.at(0)); |
| EXPECT_EQ(creditcard1, *results2.at(1)); |
| + // The message loop will exit when the mock observer is notified. |
|
dhollowa
2011/01/21 16:47:37
Are the changes in this file still needed?
|
| + MessageLoop::current()->Run(); |
| + |
| // Determine uniqueness by inserting all of the GUIDs into a set and verifying |
| // the size of the set matches the number of GUIDs. |
| std::set<std::string> guids; |
| @@ -321,13 +324,17 @@ |
| // Add a new profile. |
| AutoFillProfile profile1; |
| + // Need to be different from results2[0] by contents or it will be dropped. |
| autofill_test::SetProfileInfo(&profile1, |
| - "", "y", "", "", "", "", "", "", "", "", "", "", "", ""); |
| + "", "y", "1", "", "", "", "", "", "", "", "", "", "", ""); |
| update.clear(); |
| update.push_back(*results2[0]); |
| update.push_back(profile1); |
| personal_data_->SetProfiles(&update); |
| + // The message loop will exit when the PersonalDataLoadedObserver is notified. |
| + MessageLoop::current()->Run(); |
| + |
| // Make sure the two profiles have different ids (and neither equal to 0, |
| // which is an invalid id). |
| const std::vector<AutoFillProfile*>& results3 = personal_data_->profiles(); |
| @@ -1386,3 +1393,4 @@ |
| ASSERT_EQ(1U, results2.size()); |
| EXPECT_EQ(0, expected2.Compare(*results2[0])); |
| } |
| + |