summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHsin-Yi Chen <hsinyichen@google.com>2019-10-17 11:57:36 +0800
committerHsin-Yi Chen <hsinyichen@google.com>2019-10-17 18:01:16 +0800
commit180f4dce807217683fe52caafeebebc14e251a40 (patch)
treed2f67f0e7ff3c54c97a15b8c6eb0cd8361515b00
parentb9668048f110a688879671efb5d1ca8b3bf6b975 (diff)
downloadvndk-180f4dce807217683fe52caafeebebc14e251a40.tar.gz
Update VNDK paths in VTS test cases
VNDK-core and VNDK-SP have been moved from /system to /apex. This commit merges the test cases in VtsVndkFiles, and updates the paths in VtsVndkAbi and VtsVndkOpenLibraries. Bug: 142771034 Test: vts-tradefed run vts-vndk Change-Id: I7f8b27ddf3e0b1a3d50c6912d9eb8c97c9c20b8b
-rw-r--r--abi/VtsVndkAbiTest.py9
-rw-r--r--dependency/VtsVndkDependencyTest.py6
-rw-r--r--files/VtsVndkFilesTest.py15
-rw-r--r--open_libraries/VtsVndkOpenLibrariesTest.py3
4 files changed, 11 insertions, 22 deletions
diff --git a/abi/VtsVndkAbiTest.py b/abi/VtsVndkAbiTest.py
index 1fcbd64..554dd14 100644
--- a/abi/VtsVndkAbiTest.py
+++ b/abi/VtsVndkAbiTest.py
@@ -301,7 +301,7 @@ class VtsVndkAbiTest(base_test.BaseTestClass):
def _GetLinkerSearchIndex(target_path):
"""Returns the key for sorting linker search paths."""
index = 0
- for prefix in ("/odm", "/vendor", "/system"):
+ for prefix in ("/odm", "/vendor", "/apex"):
if target_path.startswith(prefix):
return index
index += 1
@@ -330,13 +330,10 @@ class VtsVndkAbiTest(base_test.BaseTestClass):
self._vndk_version, primary_abi, self.abi_bitness))
logging.info("dump dir: %s", dump_dir)
- target_vndk_dir = vndk_utils.GetVndkCoreDirectory(self.abi_bitness,
- self._vndk_version)
- target_vndk_sp_dir = vndk_utils.GetVndkSpDirectory(self.abi_bitness,
- self._vndk_version)
target_dirs = vndk_utils.GetVndkExtDirectories(self.abi_bitness)
target_dirs += vndk_utils.GetVndkSpExtDirectories(self.abi_bitness)
- target_dirs += [target_vndk_dir, target_vndk_sp_dir]
+ target_dirs += [vndk_utils.GetVndkDirectory(self.abi_bitness,
+ self._vndk_version)]
target_dirs.sort(key=self._GetLinkerSearchIndex)
host_dirs = [self._ToHostPath(x) for x in target_dirs]
diff --git a/dependency/VtsVndkDependencyTest.py b/dependency/VtsVndkDependencyTest.py
index 81e22b5..0ad79e7 100644
--- a/dependency/VtsVndkDependencyTest.py
+++ b/dependency/VtsVndkDependencyTest.py
@@ -46,10 +46,8 @@ class VtsVndkDependencyTest(base_test.BaseTestClass):
/system/lib[64].
_sp_hal: List of patterns. The names of the same-process HAL libraries
expected to be in /vendor/lib[64].
- _vndk: Set of strings. The names of VNDK core libraries in
- /system/lib[64]/vndk-${VER}.
- _vndk_sp: Set of strings. The names of VNDK-SP libraries in
- /system/lib[64]/vndk-sp-${VER}.
+ _vndk: Set of strings. The names of VNDK-core libraries.
+ _vndk_sp: Set of strings. The names of VNDK-SP libraries.
_SP_HAL_LINK_PATHS: Format strings of same-process HAL's link paths.
_VENDOR_LINK_PATHS: Format strings of vendor processes' link paths.
"""
diff --git a/files/VtsVndkFilesTest.py b/files/VtsVndkFilesTest.py
index 41e6386..93411ad 100644
--- a/files/VtsVndkFilesTest.py
+++ b/files/VtsVndkFilesTest.py
@@ -124,20 +124,13 @@ class VtsVndkFilesTest(base_test.BaseTestClass):
self._Fail(unexpected)
def testVndkCoreDirectory(self):
- """Verifies that VNDK-core directory doesn't contain extra files."""
+ """Verifies that VNDK directory doesn't contain extra files."""
asserts.skipIf(not vndk_utils.IsVndkRuntimeEnforced(self._dut),
"VNDK runtime is not enforced on the device.")
self._TestVndkDirectory(
- vndk_utils.GetVndkCoreDirectory(
- self.abi_bitness, self._vndk_version),
- (vndk_data.VNDK, vndk_data.VNDK_PRIVATE,))
-
- def testVndkSpDirectory(self):
- """Verifies that VNDK-SP directory doesn't contain extra files."""
- self._TestVndkDirectory(
- vndk_utils.GetVndkSpDirectory(
- self.abi_bitness, self._vndk_version),
- (vndk_data.VNDK_SP, vndk_data.VNDK_SP_PRIVATE,))
+ vndk_utils.GetVndkDirectory(self.abi_bitness, self._vndk_version),
+ (vndk_data.VNDK, vndk_data.VNDK_PRIVATE, vndk_data.VNDK_SP,
+ vndk_data.VNDK_SP_PRIVATE,))
def testNoLlndkInVendor(self):
"""Verifies that vendor partition has no LL-NDK libraries."""
diff --git a/open_libraries/VtsVndkOpenLibrariesTest.py b/open_libraries/VtsVndkOpenLibrariesTest.py
index 5a7bc33..a6b066d 100644
--- a/open_libraries/VtsVndkOpenLibrariesTest.py
+++ b/open_libraries/VtsVndkOpenLibrariesTest.py
@@ -120,7 +120,8 @@ class VtsVndkOpenLibrariesTest(base_test.BaseTestClass):
x.startswith("/vendor/")))
def _IsDisallowedSystemLib(lib_path):
- return (lib_path.startswith("/system/") and
+ return ((lib_path.startswith("/system/") or
+ lib_path.startswith("/apex/")) and
lib_path.endswith(".so") and
path_utils.TargetBaseName(lib_path) not in allowed_libs)