summaryrefslogtreecommitdiff
path: root/libnativeloader/native_loader_lazy_test.cpp
AgeCommit message (Collapse)Author
2024-04-24Repurpose libnativeloader_lazy tests as shallow tests for API coverage Martin Stjernholm
in CTS. Most APIs are exercised extensively in any managed process, but use this to cover the fringes. This drops the mocks that used dynamic library symbol overrides (android_create_namespace and android_link_namespaces) from the former libnativeloader_lazy tests, because we cannot inject them in CTS tests. However it turns out it works just fine to call into the real code in the linker. As a result libnativeloader_lazy_test no longer needs to be built with exported symbols necessary to make the symbol override mocks to work. Also strengthen the CreateClassLoaderNamespace test slightly by verifying that it really did create a classloader namespace. Also move libnativeloader_test and libnativeloader_lazy_test from device-tests to general-tests, because they shouldn't have any device dependencies. Test: atest libnativeloader_test \ art_libnativeloader_cts_test \ libnativeloader_lazy_test Bug: 335224367 Change-Id: Idd15d5a79f4f54c68304a4b758c7a46ba9b96c86
2021-06-09Avoid internal APEX stubs in libnative{bridge,loader} and clean up Martin Stjernholm
exported symbols. The APEX stubs don't have any practical effect on the lazy loading library wrappers. Add notes about that and update the function wrappers to keep them in sync. Also add tests for the lazy libraries. That necessitated some reshuffling in libnativeloader tests to reuse the mocks. Test: art/libnativebridge/tests/runtests.sh Test: atest libnativebridge-lazy-tests Test: atest libnativeloader_test libnativeloader_lazy_test Bug: 122710865 Change-Id: I7e291f2e84d8e35731dfb1114c9b19978ff87969