• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (C) 2021 The Android Open Source Project
3
4    Licensed under the Apache License, Version 2.0 (the "License");
5    you may not use this file except in compliance with the License.
6    You may obtain a copy of the License at
7
8        http://www.apache.org/licenses/LICENSE-2.0
9
10    Unless required by applicable law or agreed to in writing, software
11    distributed under the License is distributed on an "AS IS" BASIS,
12    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13    See the License for the specific language governing permissions and
14    limitations under the License.
15-->
16<configuration description="Config for libnativeloader e2e test cases">
17    <option name="test-suite-tag" value="libnativeloader_e2e_tests" />
18    <option name="test-suite-tag" value="apct" />
19    <option name="config-descriptor:metadata" key="mainline-param" value="com.google.android.art.apex" />
20
21    <target_preparer class="com.android.tradefed.targetprep.RootTargetPreparer" />
22
23    <target_preparer class="com.android.tradefed.targetprep.PushFilePreparer">
24        <!-- We push all files in LibnativeloaderTest.java, but use this
25             preparer to make partitions writable. That since remounting may
26             require a device reboot, and then it's important that the
27             `setenforce 0` from DisableSELinuxTargetPreparer occurs after that. -->
28        <option name="remount-system" value="true" />
29        <option name="remount-vendor" value="true" />
30    </target_preparer>
31
32    <!-- Vendor native libraries aren't accessible by any apps by sepolicy
33         rules. For that they need to be labelled same_process_hal_file in a
34         vendor specific file_contexts file (see
35         https://source.android.com/docs/core/permissions/namespaces_libraries#adding-additional-native-libraries).
36         To avoid setting that up to test loading libvendor_private*.so, disable
37         sepolicy checks while running the tests. It's libnativeloader logic we
38         want to test here. -->
39    <target_preparer class="com.android.tradefed.targetprep.DisableSELinuxTargetPreparer"/>
40
41    <test class="com.android.tradefed.testtype.HostTest" >
42        <option name="jar" value="libnativeloader_e2e_tests.jar" />
43    </test>
44
45    <!-- Only run tests if the device under test is SDK version 31 (Android 12) or above. -->
46    <object type="module_controller" class="com.android.tradefed.testtype.suite.module.Sdk31ModuleController" />
47</configuration>
48