Lines Matching refs:patch
38 static void verify_patch_header(const std::string& patch, size_t* num_normal, size_t* num_raw, in verify_patch_header() argument
40 const size_t size = patch.size(); in verify_patch_header()
41 const char* data = patch.data(); in verify_patch_header()
83 static void GenerateTarget(const std::string& src, const std::string& patch, std::string* patched) { in GenerateTarget() argument
86 reinterpret_cast<const unsigned char*>(patch.data()), patch.size(), in GenerateTarget()
93 static void verify_patched_image(const std::string& src, const std::string& patch, in verify_patched_image() argument
96 GenerateTarget(src, patch, &patched); in verify_patched_image()
133 std::string patch; in TEST() local
134 ASSERT_TRUE(android::base::ReadFileToString(patch_file.path, &patch)); in TEST()
140 verify_patch_header(patch, &num_normal, &num_raw, &num_deflate); in TEST()
145 verify_patched_image(src, patch, tgt); in TEST()
182 std::string patch; in TEST() local
183 ASSERT_TRUE(android::base::ReadFileToString(patch_file.path, &patch)); in TEST()
189 verify_patch_header(patch, &num_normal, &num_raw, &num_deflate); in TEST()
194 verify_patched_image(src, patch, tgt); in TEST()
236 std::string patch; in TEST() local
237 ASSERT_TRUE(android::base::ReadFileToString(patch_file.path, &patch)); in TEST()
243 verify_patch_header(patch, &num_normal, &num_raw, &num_deflate); in TEST()
248 verify_patched_image(src, patch, tgt); in TEST()
284 std::string patch; in TEST() local
285 ASSERT_TRUE(android::base::ReadFileToString(patch_file.path, &patch)); in TEST()
287 verify_patched_image(src, patch, tgt); in TEST()
332 std::string patch; in TEST() local
333 ASSERT_TRUE(android::base::ReadFileToString(patch_file.path, &patch)); in TEST()
339 verify_patch_header(patch, &num_normal, &num_raw, &num_deflate); in TEST()
344 verify_patched_image(src, patch, tgt); in TEST()
371 std::string patch; in TEST() local
372 ASSERT_TRUE(android::base::ReadFileToString(patch_file.path, &patch)); in TEST()
378 verify_patch_header(patch, &num_normal, &num_raw, &num_deflate); in TEST()
383 verify_patched_image(src, patch, tgt); in TEST()
414 std::string patch; in TEST() local
415 ASSERT_TRUE(android::base::ReadFileToString(patch_file.path, &patch)); in TEST()
416 verify_patched_image(src, patch, tgt); in TEST()
478 std::string patch; in TEST() local
479 ASSERT_TRUE(android::base::ReadFileToString(patch_file.path, &patch)); in TEST()
485 verify_patch_header(patch, &num_normal, &num_raw, &num_deflate); in TEST()
490 verify_patched_image(src, patch, tgt); in TEST()
515 std::string patch; in TEST() local
516 ASSERT_TRUE(android::base::ReadFileToString(patch_file.path, &patch)); in TEST()
522 verify_patch_header(patch, &num_normal, &num_raw, &num_deflate); in TEST()
527 verify_patched_image(src, patch, tgt); in TEST()
551 std::string patch; in TEST() local
552 ASSERT_TRUE(android::base::ReadFileToString(patch_file.path, &patch)); in TEST()
558 verify_patch_header(patch, &num_normal, &num_raw, &num_deflate); in TEST()
563 verify_patched_image(src, patch, tgt); in TEST()
587 std::string patch; in TEST() local
588 ASSERT_TRUE(android::base::ReadFileToString(patch_file.path, &patch)); in TEST()
594 verify_patch_header(patch, &num_normal, &num_raw, &num_deflate); in TEST()
599 verify_patched_image(src, patch, tgt); in TEST()
626 std::string patch; in TEST() local
627 ASSERT_TRUE(android::base::ReadFileToString(patch_file.path, &patch)); in TEST()
633 verify_patch_header(patch, &num_normal, &num_raw, &num_deflate); in TEST()
638 verify_patched_image(src, patch, tgt); in TEST()
669 std::string patch; in TEST() local
670 ASSERT_TRUE(android::base::ReadFileToString(patch_file.path, &patch)); in TEST()
671 verify_patched_image(src, patch, tgt); in TEST()
674 patch.insert(patch.end() - 10, 10, '0'); in TEST()
676 reinterpret_cast<const unsigned char*>(patch.data()), patch.size(), in TEST()