[test] Use on-demand key provisioning in AvfRkpdVmAttestationTestApp
This cl replaces the active key provisioning step in
AvfRkpdVmAttestationTestApp to on-demand, which is implicit during
the retrieval of the remotely provisioning key. This allows the
target AvfRkpdVmAttestationTestApp to remove the dependency on
rkpdapp.
Bug: 330299127
Test: atest AvfRkpdVmAttestationTestApp
Change-Id: I90d3274ac8b64db1d62f6d21d9aafe35fd664de4
diff --git a/service_vm/test_apk/AndroidTest.rkpd.xml b/service_vm/test_apk/AndroidTest.rkpd.xml
index 39eca32..8ff7bb4 100644
--- a/service_vm/test_apk/AndroidTest.rkpd.xml
+++ b/service_vm/test_apk/AndroidTest.rkpd.xml
@@ -17,22 +17,18 @@
<option name="test-suite-tag" value="apct" />
<option name="test-suite-tag" value="apct-instrumentation" />
- <!-- Need to disable SELinux policy to allow com.android.rkpdapp to run a VM. -->
- <target_preparer class="com.android.tradefed.targetprep.DisableSELinuxTargetPreparer"/>
+ <target_preparer class="com.android.tradefed.targetprep.DeviceSetup">
+ <!-- The host name is needed for RKPD key provisioning -->
+ <option name="set-property" key="remote_provisioning.hostname"
+ value="remoteprovisioning.googleapis.com" />
+ <option name="restore-properties" value="true"/>
+ </target_preparer>
<target_preparer class="com.android.tradefed.targetprep.suite.SuiteApkInstaller">
<option name="test-file-name" value="AvfRkpdVmAttestationTestApp.apk" />
- <option name="test-file-name" value="avf-rkpdapp.apk" />
</target_preparer>
<test class="com.android.tradefed.testtype.AndroidJUnitTest" >
<option name="package" value="com.android.virt.rkpd.vm_attestation.testapp" />
</test>
-
- <!-- Only run if RKPD mainline module is installed -->
- <object type="module_controller"
- class="com.android.tradefed.testtype.suite.module.MainlineTestModuleController">
- <option name="enable" value="true" />
- <option name="mainline-module-package-name" value="com.android.rkpd" />
- </object>
</configuration>