Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7d6a7c5f authored by Guang Zhu's avatar Guang Zhu
Browse files

use test app's data folder as filter directory

During a retry, test methods to be retried are written into a
file, pushed onto device and read by the test instrumentation
for execution.

The default location for such filter file is /data/local/tmp,
which is prohibited for access by system uid packages, such
as the system UI tests package.

This change uses the test app's data folder for filter: this
is not generally applicable for all the tests since root
permission is required, but it is a relatively safe assumption
in case of testing against system uid pakcages since it
implies userdebug build is being used.

Bug: 152001555
Fixes: 208473429
Test: http://go/forrest-run/L76200000952166377
Change-Id: Ifc268a1cdb94ff8e47b6bd323464deb28e0c20ea
parent 1a9af383
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -18,12 +18,17 @@
        <option name="test-file-name" value="SystemUITests.apk" />
    </target_preparer>

    <target_preparer class="com.android.tradefed.targetprep.RootTargetPreparer">
        <option name="force-root" value="true" />
    </target_preparer>

    <option name="test-suite-tag" value="apct" />
    <option name="test-suite-tag" value="framework-base-presubmit" />
    <option name="test-tag" value="SystemUITests" />
    <test class="com.android.tradefed.testtype.AndroidJUnitTest" >
        <option name="package" value="com.android.systemui.tests" />
        <option name="runner" value="android.testing.TestableInstrumentation" />
        <option name="test-filter-dir" value="/data/data/com.android.systemui.tests" />
        <option name="hidden-api-checks" value="false"/>
    </test>
</configuration>