1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (C) 2015 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="CTS precondition configs">
17
18    <include name="cts-device-files" />
19
20    <option name="plan" value="cts-preconditions" />
21
22    <target_preparer class="com.android.compatibility.common.tradefed.targetprep.DynamicConfigPusher">
23        <option name="target" value="host" />
24        <!-- the name under which to find the configuration -->
25        <option name="config-filename" value="cts" />
26        <option name="extract-from-resource" value="true" />
27        <!-- the name of the resource inside the jar -->
28        <option name="dynamic-resource-name" value="cts-tradefed" />
29    </target_preparer>
30
31    <target_preparer class="com.android.compatibility.common.tradefed.targetprep.StayAwakePreparer" />
32
33    <!-- Disable "Android Beta Program" -->
34    <target_preparer class="com.android.compatibility.common.tradefed.targetprep.PackageDisabler" >
35        <option name="package" value="com.android.yadayada"/>
36    </target_preparer>
37
38    <target_preparer class="com.android.compatibility.common.tradefed.targetprep.SettingsPreparer">
39        <option name="device-setting" value="verifier_verify_adb_installs"/>
40        <option name="setting-type" value="global"/>
41        <option name="set-value" value="0"/>
42    </target_preparer>
43
44    <!-- Disable crash error dialogs to avoid affecting following tests -->
45    <target_preparer class="com.android.compatibility.common.tradefed.targetprep.SettingsPreparer">
46        <option name="device-setting" value="hide_error_dialogs"/>
47        <option name="setting-type" value="global"/>
48        <option name="set-value" value="1"/>
49    </target_preparer>
50
51    <target_preparer class="com.android.compatibility.common.tradefed.targetprep.ApkPreconditionCheck">
52        <option name="apk" value="CtsPreconditions.apk"/>
53        <option name="package" value="com.android.preconditions.cts"/>
54    </target_preparer>
55
56    <target_preparer class="com.android.compatibility.common.tradefed.targetprep.WifiCheck" />
57
58    <target_preparer class="com.android.tradefed.targetprep.RunCommandTargetPreparer">
59        <option name="run-command" value="rm -rf /sdcard/device-info-files" />
60        <option name="run-command" value="rm -rf /sdcard/report-log-files" />
61        <!-- Disable keyguard -->
62        <option name="run-command" value="locksettings set-disabled true"/>
63    </target_preparer>
64
65    <target_preparer class="com.android.compatibility.common.tradefed.targetprep.DeviceInfoCollector">
66        <option name="apk" value="CtsDeviceInfo.apk"/>
67        <option name="package" value="com.android.compatibility.common.deviceinfo"/>
68        <option name="src-dir" value="/sdcard/device-info-files/"/>
69        <option name="dest-dir" value="device-info-files/"/>
70        <option name="temp-dir" value="temp-device-info-files/"/>
71        <option name="throw-error" value="false"/>
72    </target_preparer>
73
74    <!-- The following values are used in cts/common/device-side/util/DeviceReportLog.java,
75    cts/harness/common/host-side/util/MetricsReportLog.java and tools/tradefed-host/util/ReportLogUtil.java.
76    Any change in these values must also be translated to the stated files.
77    -->
78    <target_preparer class="com.android.compatibility.common.tradefed.targetprep.ReportLogCollector">
79        <option name="src-dir" value="/sdcard/report-log-files/"/>
80        <option name="dest-dir" value="report-log-files/"/>
81        <option name="temp-dir" value="temp-report-logs/"/>
82    </target_preparer>
83</configuration>
84