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
17<!-- This manifest is to create the apk of CtsSplitInstantApp for the tests of the splitName of
18     component such as Service and Provider. They are only supported in the instant app. In the full
19     app, declares a provider which is not defined in the apk would crash the application while
20     application is launching. A specific apk for these tests is needed.
21-->
22<manifest xmlns:android="http://schemas.android.com/apk/res/android"
23     xmlns:tools="http://schemas.android.com/tools"
24     package="com.android.cts.splitapp"
25     android:targetSandboxVersion="2">
26
27    <!-- The androidx test libraries uses minSdkVersion 14. Applies an overrideLibrary rule here
28         to pass the build error, since tests need to use minSdkVersion 4. -->
29    <uses-sdk android:minSdkVersion="4" tools:overrideLibrary="androidx.test.runner,
30        androidx.test.rules, androidx.test.monitor, androidx.test.services.storage,
31        androidx.test.annotation, androidx.annotation.experimental, androidx.tracing"/>
32
33    <uses-permission android:name="android.permission.CAMERA"/>
34    <uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED"/>
35    <uses-permission android:name="android.permission.QUERY_ALL_PACKAGES"/>
36
37    <application android:label="SplitApp"
38         android:multiArch="true">
39        <activity android:name=".MyActivity"
40             android:exported="true">
41            <intent-filter>
42                <action android:name="android.intent.action.MAIN"/>
43                <category android:name="android.intent.category.LAUNCHER"/>
44            </intent-filter>
45            <meta-data android:name="android.service.wallpaper"
46                 android:resource="@xml/my_activity_meta"/>
47        </activity>
48        <activity android:name=".ThemeActivity" android:theme="@style/Theme_Base"
49                  android:exported="false">
50            <intent-filter>
51                <action android:name="com.android.cts.splitapp.intent.THEME_TEST"/>
52                <category android:name="android.intent.category.DEFAULT"/>
53            </intent-filter>
54        </activity>
55        <activity android:name=".feature.warm.EmptyActivity" android:splitName="feature_warm"
56                  android:exported="true">
57            <intent-filter>
58                <action android:name="com.android.cts.splitapp.intent.SPLIT_NAME_TEST"/>
59                <category android:name="android.intent.category.DEFAULT"/>
60            </intent-filter>
61        </activity>
62        <receiver android:name=".MyReceiver"
63             android:enabled="@bool/my_receiver_enabled"
64             android:exported="true">
65            <intent-filter>
66                <action android:name="android.intent.action.DATE_CHANGED"/>
67            </intent-filter>
68        </receiver>
69        <receiver android:name=".LockedBootReceiver"
70             android:exported="true"
71             android:directBootAware="true">
72            <intent-filter>
73                <action android:name="android.intent.action.LOCKED_BOOT_COMPLETED"/>
74            </intent-filter>
75        </receiver>
76        <receiver android:name=".BootReceiver"
77             android:exported="true">
78            <intent-filter>
79                <action android:name="android.intent.action.BOOT_COMPLETED"/>
80            </intent-filter>
81        </receiver>
82
83        <provider android:name=".RemoteQueryProvider"
84             android:authorities="com.android.cts.splitapp"
85             android:exported="true"
86             android:directBootAware="true">
87        </provider>
88        <!-- Provider defined in the split of feature_warm. -->
89        <provider android:name=".feature.warm.EmptyProvider" android:splitName="feature_warm"
90                  android:authorities="com.android.cts.splitapp.feature.warm"
91                  android:exported="true">
92            <intent-filter>
93                <action android:name="com.android.cts.splitapp.intent.SPLIT_NAME_TEST"/>
94            </intent-filter>
95        </provider>
96
97        <!-- Service defined in the split of feature_warm. -->
98        <service android:name=".feature.warm.EmptyService" android:splitName="feature_warm"
99                 android:exported="true">
100            <intent-filter>
101                <action android:name="com.android.cts.splitapp.intent.SPLIT_NAME_TEST"/>
102            </intent-filter>
103        </service>
104
105        <uses-library android:name="android.test.runner"/>
106    </application>
107
108    <instrumentation android:name="androidx.test.runner.AndroidJUnitRunner"
109         android:targetPackage="com.android.cts.splitapp"/>
110
111</manifest>
112