diff options
author | Kiyoung Kim <kiyoungkim@google.com> | 2020-01-29 16:09:38 +0900 |
---|---|---|
committer | Kiyoung Kim <kiyoungkim@google.com> | 2020-02-07 03:25:40 +0000 |
commit | 99c19ca707391f0908313c7cee2ef315d2b5cb3c (patch) | |
tree | c5213c3eb212732c88cc455e8ca67c1990d29767 /libnativeloader/native_loader_test.cpp | |
parent | cf0c6ef642517fba3bc9a211acaed742ff39b86d (diff) |
Update platform namespace name
Platform namespace has been renamed as 'system' from linkerconfig
generator. To meet this requirement, libnativeloader should search for
namespace 'system' rather than namespace 'platform'.
Bug: 147987608
Test: m -j passed
Test: atest libnativeloader_test passed
Change-Id: I23d865ac71a80619f291eb9ae0761a2cad5df352
Diffstat (limited to 'libnativeloader/native_loader_test.cpp')
-rw-r--r-- | libnativeloader/native_loader_test.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libnativeloader/native_loader_test.cpp b/libnativeloader/native_loader_test.cpp index 88964b7a85..46483773e6 100644 --- a/libnativeloader/native_loader_test.cpp +++ b/libnativeloader/native_loader_test.cpp @@ -92,7 +92,7 @@ class Platform { // These represents built-in namespaces created by the linker according to ld.config.txt static std::unordered_map<std::string, Platform::mock_namespace_handle> namespaces = { - {"platform", TO_MOCK_NAMESPACE(TO_ANDROID_NAMESPACE("platform"))}, + {"system", TO_MOCK_NAMESPACE(TO_ANDROID_NAMESPACE("system"))}, {"default", TO_MOCK_NAMESPACE(TO_ANDROID_NAMESPACE("default"))}, {"art", TO_MOCK_NAMESPACE(TO_ANDROID_NAMESPACE("art"))}, {"sphal", TO_MOCK_NAMESPACE(TO_ANDROID_NAMESPACE("sphal"))}, @@ -348,7 +348,7 @@ class NativeLoaderTest_Create : public NativeLoaderTest { ANDROID_NAMESPACE_TYPE_ISOLATED | ANDROID_NAMESPACE_TYPE_ALSO_USED_AS_ANONYMOUS; std::string expected_library_path = library_path; std::string expected_permitted_path = std::string("/data:/mnt/expand:") + permitted_path; - std::string expected_parent_namespace = "platform"; + std::string expected_parent_namespace = "system"; bool expected_link_with_platform_ns = true; bool expected_link_with_art_ns = true; bool expected_link_with_sphal_ns = !vendor_public_libraries().empty(); @@ -378,7 +378,7 @@ class NativeLoaderTest_Create : public NativeLoaderTest { StrEq(expected_permitted_path), NsEq(expected_parent_namespace.c_str()))) .WillOnce(Return(TO_MOCK_NAMESPACE(TO_ANDROID_NAMESPACE(dex_path.c_str())))); if (expected_link_with_platform_ns) { - EXPECT_CALL(*mock, mock_link_namespaces(Eq(IsBridged()), _, NsEq("platform"), + EXPECT_CALL(*mock, mock_link_namespaces(Eq(IsBridged()), _, NsEq("system"), StrEq(expected_shared_libs_to_platform_ns))) .WillOnce(Return(true)); } |