From c8cf2a4155dd297dc2b55ab362593cba52060c97 Mon Sep 17 00:00:00 2001 From: Tianjie Date: Thu, 28 Oct 2021 21:49:05 -0700 Subject: [PATCH] Fix unittest that checks build id Should check ro.build.id instead of the ro.boot.build.id. The former is a component of the build fingerprint. Bug: 204507710 Test: run CtsInitTestCases Change-Id: Iee13b30b195685c2461255f946685a288f352e06 --- init/property_service_test.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/init/property_service_test.cpp b/init/property_service_test.cpp index ac6b7b271..5f34cc4da 100644 --- a/init/property_service_test.cpp +++ b/init/property_service_test.cpp @@ -99,7 +99,7 @@ TEST(property_service, check_fingerprint_with_legacy_build_id) { std::string vbmeta_digest = GetProperty("ro.boot.vbmeta.digest", ""); ASSERT_GE(vbmeta_digest.size(), 8u); - std::string build_id = GetProperty("ro.boot.build.id", ""); + std::string build_id = GetProperty("ro.build.id", ""); // Check that the build id is constructed with the prefix of vbmeta digest std::string expected_build_id = legacy_build_id + "." + vbmeta_digest.substr(0, 8); ASSERT_EQ(expected_build_id, build_id);