From 09e468f84cc245fba61d69165b4af8f1ec4cdfd5 Mon Sep 17 00:00:00 2001 From: Tao Bao Date: Fri, 29 Sep 2017 14:39:33 -0700 Subject: Move rangeset.h and print_sha1.h into otautil. Also drop the "bootable/recovery" path in LOCAL_C_INCLUDES from applypatch modules. Test: lunch aosp_{angler,bullhead,fugu,dragon,sailfish}-userdebug; mmma bootable/recovery Change-Id: Idd602a796894f971ee4f8fa3eafe36c42d9de986 --- tests/Android.mk | 1 + tests/component/applypatch_test.cpp | 2 +- tests/component/updater_test.cpp | 2 +- tests/unit/rangeset_test.cpp | 4 ++-- 4 files changed, 5 insertions(+), 4 deletions(-) (limited to 'tests') diff --git a/tests/Android.mk b/tests/Android.mk index 31c7de177..b0f71a832 100644 --- a/tests/Android.mk +++ b/tests/Android.mk @@ -201,6 +201,7 @@ LOCAL_SRC_FILES := \ LOCAL_STATIC_LIBRARIES := \ libimgdiff \ libimgpatch \ + libotautil \ libbsdiff \ libbspatch \ libziparchive \ diff --git a/tests/component/applypatch_test.cpp b/tests/component/applypatch_test.cpp index 42542898b..15ec08fe7 100644 --- a/tests/component/applypatch_test.cpp +++ b/tests/component/applypatch_test.cpp @@ -35,7 +35,7 @@ #include "applypatch/applypatch.h" #include "applypatch/applypatch_modes.h" #include "common/test_constants.h" -#include "print_sha1.h" +#include "otautil/print_sha1.h" static void sha1sum(const std::string& fname, std::string* sha1, size_t* fsize = nullptr) { ASSERT_NE(nullptr, sha1); diff --git a/tests/component/updater_test.cpp b/tests/component/updater_test.cpp index e35870dc7..e6aec4ad6 100644 --- a/tests/component/updater_test.cpp +++ b/tests/component/updater_test.cpp @@ -41,7 +41,7 @@ #include "edify/expr.h" #include "otautil/SysUtil.h" #include "otautil/error_code.h" -#include "print_sha1.h" +#include "otautil/print_sha1.h" #include "updater/blockimg.h" #include "updater/install.h" #include "updater/updater.h" diff --git a/tests/unit/rangeset_test.cpp b/tests/unit/rangeset_test.cpp index 15bcec855..b3ed99215 100644 --- a/tests/unit/rangeset_test.cpp +++ b/tests/unit/rangeset_test.cpp @@ -21,7 +21,7 @@ #include -#include "rangeset.h" +#include "otautil/rangeset.h" TEST(RangeSetTest, Parse_smoke) { RangeSet rs = RangeSet::Parse("2,1,10"); @@ -156,4 +156,4 @@ TEST(SortedRangeSetTest, file_range) { ASSERT_EQ(static_cast(40970), rs.GetOffsetInRangeSet(4096 * 16 + 10)); // block#10 not in range. ASSERT_EXIT(rs.GetOffsetInRangeSet(40970), ::testing::KilledBySignal(SIGABRT), ""); -} \ No newline at end of file +} -- cgit v1.2.3