diff options
author | Alex Vakulenko <avakulenko@chromium.org> | 2015-02-09 12:53:18 -0800 |
---|---|---|
committer | ChromeOS Commit Bot <chromeos-commit-bot@chromium.org> | 2015-02-11 06:00:18 +0000 |
commit | f68bbbc952aa9a71898e4939b5f36187fa564a50 (patch) | |
tree | 3927ffc053db9275a052ba2a370cbae62b5c236a /filesystem_copier_action_unittest.cc | |
parent | 981a9fb68ec5fe56f57b3ecb117a0dc681bf5e83 (diff) |
update_engine: replace std::vector<char> with chromeos::Blob
To make update engine consistent with the rest of platform2 code
replaced std::vector<char> as the container of binary data with
chromeos::Blob.
BUG=None
TEST=`FEATURES=test emerge-link update_engine`
Change-Id: I6385fd2257d15aa24bfa74ac35512c2a06c33012
Reviewed-on: https://chromium-review.googlesource.com/247793
Reviewed-by: Gilad Arnold <garnold@chromium.org>
Reviewed-by: Alex Deymo <deymo@chromium.org>
Tested-by: Alex Vakulenko <avakulenko@chromium.org>
Commit-Queue: Alex Vakulenko <avakulenko@chromium.org>
Diffstat (limited to 'filesystem_copier_action_unittest.cc')
-rw-r--r-- | filesystem_copier_action_unittest.cc | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/filesystem_copier_action_unittest.cc b/filesystem_copier_action_unittest.cc index 5973fb64..5b4c3ab6 100644 --- a/filesystem_copier_action_unittest.cc +++ b/filesystem_copier_action_unittest.cc @@ -139,12 +139,12 @@ bool FilesystemCopierActionTest::DoTest(bool run_out_of_space, // Make random data for a, zero filled data for b. const size_t kLoopFileSize = 10 * 1024 * 1024 + 512; - vector<char> a_loop_data(kLoopFileSize); + chromeos::Blob a_loop_data(kLoopFileSize); test_utils::FillWithData(&a_loop_data); - vector<char> b_loop_data(run_out_of_space ? - (kLoopFileSize - 1) : - kLoopFileSize, - '\0'); // Fill with 0s + chromeos::Blob b_loop_data(run_out_of_space ? + (kLoopFileSize - 1) : + kLoopFileSize, + 0); // Fill with 0s // Write data to disk if (!(test_utils::WriteFileVector(a_loop_file, a_loop_data) && @@ -254,7 +254,7 @@ bool FilesystemCopierActionTest::DoTest(bool run_out_of_space, EXPECT_EQ(ErrorCode::kSuccess, delegate.code()); // Make sure everything in the out_image is there - vector<char> a_out; + chromeos::Blob a_out; if (!utils::ReadFile(a_dev, &a_out)) { ADD_FAILURE(); return false; @@ -264,7 +264,7 @@ bool FilesystemCopierActionTest::DoTest(bool run_out_of_space, EXPECT_TRUE(is_a_file_reading_eq); success = success && is_a_file_reading_eq; if (!verify_hash) { - vector<char> b_out; + chromeos::Blob b_out; if (!utils::ReadFile(b_dev, &b_out)) { ADD_FAILURE(); return false; |