| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/chromeos/login/signed_settings_helper.h" | 5 #include "chrome/browser/chromeos/login/signed_settings_helper.h" |
| 6 | 6 |
| 7 #include "chrome/browser/browser_thread.h" | 7 #include "chrome/browser/browser_thread.h" |
| 8 #include "chrome/browser/chromeos/cros/cros_library.h" | 8 #include "chrome/browser/chromeos/cros/cros_library.h" |
| 9 #include "chrome/browser/chromeos/login/mock_ownership_service.h" | 9 #include "chrome/browser/chromeos/login/mock_ownership_service.h" |
| 10 #include "chrome/browser/chromeos/login/owner_manager.h" | 10 #include "chrome/browser/chromeos/login/owner_manager.h" |
| (...skipping 21 matching lines...) Expand all Loading... |
| 32 MOCK_METHOD3(OnRetrievePropertyCompleted, void( | 32 MOCK_METHOD3(OnRetrievePropertyCompleted, void( |
| 33 SignedSettings::ReturnCode code, | 33 SignedSettings::ReturnCode code, |
| 34 const std::string& name, | 34 const std::string& name, |
| 35 const std::string& value)); | 35 const std::string& value)); |
| 36 }; | 36 }; |
| 37 | 37 |
| 38 class SignedSettingsHelperTest : public ::testing::Test, | 38 class SignedSettingsHelperTest : public ::testing::Test, |
| 39 public SignedSettingsHelper::TestDelegate { | 39 public SignedSettingsHelper::TestDelegate { |
| 40 public: | 40 public: |
| 41 SignedSettingsHelperTest() | 41 SignedSettingsHelperTest() |
| 42 : fake_email_("fakey"), | 42 : fake_email_("fakey@example.com"), |
| 43 fake_prop_("prop_name"), | 43 fake_prop_("prop_name"), |
| 44 fake_value_("stub"), | 44 fake_value_("stub"), |
| 45 message_loop_(MessageLoop::TYPE_UI), | 45 message_loop_(MessageLoop::TYPE_UI), |
| 46 ui_thread_(BrowserThread::UI, &message_loop_), | 46 ui_thread_(BrowserThread::UI, &message_loop_), |
| 47 file_thread_(BrowserThread::FILE), | 47 file_thread_(BrowserThread::FILE), |
| 48 pending_ops_(0) { | 48 pending_ops_(0) { |
| 49 } | 49 } |
| 50 | 50 |
| 51 virtual void SetUp() { | 51 virtual void SetUp() { |
| 52 file_thread_.Start(); | 52 file_thread_.Start(); |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 SignedSettingsHelper::Get()->CancelCallback(&cb_to_be_canceled); | 155 SignedSettingsHelper::Get()->CancelCallback(&cb_to_be_canceled); |
| 156 | 156 |
| 157 SignedSettingsHelper::Get()->StartStorePropertyOp(fake_prop_, fake_value_, | 157 SignedSettingsHelper::Get()->StartStorePropertyOp(fake_prop_, fake_value_, |
| 158 &cb); | 158 &cb); |
| 159 SignedSettingsHelper::Get()->StartRetrieveProperty(fake_prop_, &cb); | 159 SignedSettingsHelper::Get()->StartRetrieveProperty(fake_prop_, &cb); |
| 160 | 160 |
| 161 message_loop_.Run(); | 161 message_loop_.Run(); |
| 162 } | 162 } |
| 163 | 163 |
| 164 } // namespace chromeos | 164 } // namespace chromeos |
| OLD | NEW |