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

Unified Diff: chrome/browser/sync/sync_setup_wizard_unittest.cc

Issue 6902101: Refactor sync passphrase setup flow and fix passphrase tests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: de Morgan's law simplification. Created 9 years, 8 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/sync_setup_wizard_unittest.cc
diff --git a/chrome/browser/sync/sync_setup_wizard_unittest.cc b/chrome/browser/sync/sync_setup_wizard_unittest.cc
index 72ef033df526d8a00670730762385ba67970fdf4..e0970c0cf47d850e5a82f3ace3a13296e9f0f804 100644
--- a/chrome/browser/sync/sync_setup_wizard_unittest.cc
+++ b/chrome/browser/sync/sync_setup_wizard_unittest.cc
@@ -11,6 +11,7 @@
#include "base/stl_util-inl.h"
#include "base/utf_string_conversions.h"
#include "chrome/browser/prefs/pref_service.h"
+#include "chrome/browser/sync/engine/syncapi.h"
#include "chrome/browser/sync/profile_sync_factory_mock.h"
#include "chrome/browser/sync/profile_sync_service.h"
#include "chrome/browser/sync/sync_setup_flow.h"
@@ -78,8 +79,8 @@ class ProfileSyncServiceForWizardTest : public ProfileSyncService {
last_auth_error_ = error;
}
- void set_passphrase_required(bool required) {
- observed_passphrase_required_ = required;
+ void SetPassphraseRequiredReason(sync_api::PassphraseRequiredReason reason) {
+ passphrase_required_reason_ = reason;
}
void ResetTestStats() {
@@ -337,7 +338,7 @@ TEST_F(SyncSetupWizardTest, DISABLED_EnterPassphraseRequired) {
wizard_->Step(SyncSetupWizard::GAIA_SUCCESS);
wizard_->Step(SyncSetupWizard::CONFIGURE);
wizard_->Step(SyncSetupWizard::SETTING_UP);
- service_->set_passphrase_required(true);
+ service_->SetPassphraseRequiredReason(sync_api::REASON_ENCRYPTION);
wizard_->Step(SyncSetupWizard::ENTER_PASSPHRASE);
EXPECT_EQ(SyncSetupWizard::ENTER_PASSPHRASE,
test_window_->flow()->current_state_);

Powered by Google App Engine
This is Rietveld 408576698