OLD | NEW |
1 // Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium OS 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 <base/file_util.h> | 5 #include <base/file_util.h> |
6 #include <gtest/gtest.h> | 6 #include <gtest/gtest.h> |
7 | 7 |
8 #include "update_engine/action_mock.h" | 8 #include "update_engine/action_mock.h" |
9 #include "update_engine/action_processor_mock.h" | 9 #include "update_engine/action_processor_mock.h" |
10 #include "update_engine/filesystem_copier_action.h" | 10 #include "update_engine/filesystem_copier_action.h" |
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
245 | 245 |
246 namespace { | 246 namespace { |
247 const string kActionTypes[] = { | 247 const string kActionTypes[] = { |
248 OmahaRequestAction::StaticType(), | 248 OmahaRequestAction::StaticType(), |
249 OmahaResponseHandlerAction::StaticType(), | 249 OmahaResponseHandlerAction::StaticType(), |
250 FilesystemCopierAction::StaticType(), | 250 FilesystemCopierAction::StaticType(), |
251 FilesystemCopierAction::StaticType(), | 251 FilesystemCopierAction::StaticType(), |
252 OmahaRequestAction::StaticType(), | 252 OmahaRequestAction::StaticType(), |
253 DownloadAction::StaticType(), | 253 DownloadAction::StaticType(), |
254 OmahaRequestAction::StaticType(), | 254 OmahaRequestAction::StaticType(), |
| 255 OmahaRequestAction::StaticType(), |
255 FilesystemCopierAction::StaticType(), | 256 FilesystemCopierAction::StaticType(), |
256 FilesystemCopierAction::StaticType(), | 257 FilesystemCopierAction::StaticType(), |
257 PostinstallRunnerAction::StaticType(), | 258 PostinstallRunnerAction::StaticType(), |
258 OmahaRequestAction::StaticType() | 259 OmahaRequestAction::StaticType() |
259 }; | 260 }; |
260 } // namespace {} | 261 } // namespace {} |
261 | 262 |
262 void UpdateAttempterTest::UpdateTestStart() { | 263 void UpdateAttempterTest::UpdateTestStart() { |
263 attempter_.set_http_response_code(200); | 264 attempter_.set_http_response_code(200); |
264 InSequence s; | 265 InSequence s; |
(...skipping 27 matching lines...) Expand all Loading... |
292 | 293 |
293 TEST_F(UpdateAttempterTest, UpdateTest) { | 294 TEST_F(UpdateAttempterTest, UpdateTest) { |
294 loop_ = g_main_loop_new(g_main_context_default(), FALSE); | 295 loop_ = g_main_loop_new(g_main_context_default(), FALSE); |
295 g_idle_add(&StaticUpdateTestStart, this); | 296 g_idle_add(&StaticUpdateTestStart, this); |
296 g_main_loop_run(loop_); | 297 g_main_loop_run(loop_); |
297 g_main_loop_unref(loop_); | 298 g_main_loop_unref(loop_); |
298 loop_ = NULL; | 299 loop_ = NULL; |
299 } | 300 } |
300 | 301 |
301 } // namespace chromeos_update_engine | 302 } // namespace chromeos_update_engine |
OLD | NEW |