Lines Matching refs:src

84 static void GenerateTarget(const std::string& src, const std::string& patch, std::string* patched) {  in GenerateTarget()  argument
86 ASSERT_EQ(0, ApplyImagePatch(reinterpret_cast<const unsigned char*>(src.data()), src.size(), in GenerateTarget()
94 static void verify_patched_image(const std::string& src, const std::string& patch, in verify_patched_image() argument
97 GenerateTarget(src, patch, &patched); in verify_patched_image()
119 const std::string src("abcdefg"); in TEST() local
121 ASSERT_TRUE(android::base::WriteStringToFile(src, src_file.path)); in TEST()
146 verify_patched_image(src, patch, tgt); in TEST()
181 std::string src; in TEST() local
182 ASSERT_TRUE(android::base::ReadFileToString(src_file.path, &src)); in TEST()
195 verify_patched_image(src, patch, tgt); in TEST()
235 std::string src; in TEST() local
236 ASSERT_TRUE(android::base::ReadFileToString(src_file.path, &src)); in TEST()
249 verify_patched_image(src, patch, tgt); in TEST()
283 std::string src; in TEST() local
284 ASSERT_TRUE(android::base::ReadFileToString(src_file.path, &src)); in TEST()
288 verify_patched_image(src, patch, tgt); in TEST()
331 std::string src; in TEST() local
332 ASSERT_TRUE(android::base::ReadFileToString(src_file.path, &src)); in TEST()
345 verify_patched_image(src, patch, tgt); in TEST()
353 const std::string src = "abcdefg" + gzipped_source; in TEST() local
355 ASSERT_TRUE(android::base::WriteStringToFile(src, src_file.path)); in TEST()
384 verify_patched_image(src, patch, tgt); in TEST()
394 const std::string src(src_data.cbegin(), src_data.cend()); in TEST() local
396 ASSERT_TRUE(android::base::WriteStringToFile(src, src_file.path)); in TEST()
417 verify_patched_image(src, patch, tgt); in TEST()
429 const std::string src(src_data.cbegin(), src_data.cend()); in TEST() local
431 ASSERT_TRUE(android::base::WriteStringToFile(src, src_file.path)); in TEST()
456 const std::string src = "abcdefg" + gzipped_source; in TEST() local
458 ASSERT_TRUE(android::base::WriteStringToFile(src, src_file.path)); in TEST()
491 verify_patched_image(src, patch, tgt); in TEST()
499 const std::string src(src_data.cbegin(), src_data.cend()); in TEST() local
501 ASSERT_TRUE(android::base::WriteStringToFile(src, src_file.path)); in TEST()
528 verify_patched_image(src, patch, tgt); in TEST()
535 const std::string src(src_data.cbegin(), src_data.cend()); in TEST() local
537 ASSERT_TRUE(android::base::WriteStringToFile(src, src_file.path)); in TEST()
564 verify_patched_image(src, patch, tgt); in TEST()
571 const std::string src(src_data.cbegin(), src_data.cend()); in TEST() local
573 ASSERT_TRUE(android::base::WriteStringToFile(src, src_file.path)); in TEST()
600 verify_patched_image(src, patch, tgt); in TEST()
608 const std::string src(src_data.cbegin(), src_data.cend()); in TEST() local
610 ASSERT_TRUE(android::base::WriteStringToFile(src, src_file.path)); in TEST()
639 verify_patched_image(src, patch, tgt); in TEST()
649 const std::string src(src_data.cbegin(), src_data.cend()); in TEST() local
651 ASSERT_TRUE(android::base::WriteStringToFile(src, src_file.path)); in TEST()
672 verify_patched_image(src, patch, tgt); in TEST()
676 ASSERT_EQ(-1, ApplyImagePatch(reinterpret_cast<const unsigned char*>(src.data()), src.size(), in TEST()