OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "chromeos/dbus/fake_update_engine_client.h" | 5 #include "chromeos/dbus/fake_update_engine_client.h" |
6 | 6 |
7 namespace chromeos { | 7 namespace chromeos { |
8 | 8 |
9 FakeUpdateEngineClient::FakeUpdateEngineClient() | 9 FakeUpdateEngineClient::FakeUpdateEngineClient() |
10 : update_check_result_(UpdateEngineClient::UPDATE_RESULT_SUCCESS), | 10 : update_check_result_(UpdateEngineClient::UPDATE_RESULT_SUCCESS), |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 | 42 |
43 UpdateEngineClient::Status FakeUpdateEngineClient::GetLastStatus() { | 43 UpdateEngineClient::Status FakeUpdateEngineClient::GetLastStatus() { |
44 if (status_queue_.empty()) | 44 if (status_queue_.empty()) |
45 return default_status_; | 45 return default_status_; |
46 | 46 |
47 UpdateEngineClient::Status last_status = status_queue_.front(); | 47 UpdateEngineClient::Status last_status = status_queue_.front(); |
48 status_queue_.pop(); | 48 status_queue_.pop(); |
49 return last_status; | 49 return last_status; |
50 } | 50 } |
51 | 51 |
| 52 void FakeUpdateEngineClient::SetChannel(const std::string& target_channel, |
| 53 bool is_powerwash_allowed) { |
| 54 } |
| 55 |
| 56 void FakeUpdateEngineClient::GetChannel(bool get_current_channel, |
| 57 const GetChannelCallback& callback) { |
| 58 } |
| 59 |
52 void FakeUpdateEngineClient::set_default_status( | 60 void FakeUpdateEngineClient::set_default_status( |
53 const UpdateEngineClient::Status& status) { | 61 const UpdateEngineClient::Status& status) { |
54 default_status_ = status; | 62 default_status_ = status; |
55 } | 63 } |
56 | 64 |
57 void FakeUpdateEngineClient::set_update_check_result( | 65 void FakeUpdateEngineClient::set_update_check_result( |
58 const UpdateEngineClient::UpdateCheckResult& result) { | 66 const UpdateEngineClient::UpdateCheckResult& result) { |
59 update_check_result_ = result; | 67 update_check_result_ = result; |
60 } | 68 } |
61 | 69 |
62 } // namespace chromeos | 70 } // namespace chromeos |
OLD | NEW |