Add test that makes fd_server use of fs-verity ioctl

Although we're only using fd_server to read Merkle tree from .fsv_meta
currently, fd_server actually supports reading the tree from a fs-verity
protected file using ioctl.

This change adds a test case for that, by configuring fd_server with
`--ro-fds 3` instead of something like `--ro-fds 3:4` where 4 is the
alternative fs-verity metadata source (.fsv_meta).

Also removed an obsolete TODO.

Bug: 183749054
Test: atest AuthFsHostTest

Change-Id: Ib633d8792048ac17c5f84fd987aa09ff538cf29d
diff --git a/authfs/tests/AndroidTest.xml b/authfs/tests/AndroidTest.xml
index cc358f2..2ccc45f 100644
--- a/authfs/tests/AndroidTest.xml
+++ b/authfs/tests/AndroidTest.xml
@@ -34,6 +34,7 @@
 
         <!-- Test executable -->
         <option name="push-file" key="open_then_run" value="/data/local/tmp/open_then_run" />
+        <option name="push-file" key="fsverity" value="/data/local/tmp/fsverity" />
 
         <!-- Test data files -->
         <option name="push-file" key="cert.der" value="/data/local/tmp/authfs/cert.der" />
@@ -48,6 +49,19 @@
             value="/data/local/tmp/authfs/input.4k.fsv_meta" />
         <option name="push-file" key="input.4m.fsv_meta.bad_merkle"
             value="/data/local/tmp/authfs/input.4m.fsv_meta.bad_merkle" />
+
+        <!-- Just pick a file with signature that can be trused on the device. -->
+        <option name="push-file" key="CtsApkVerityTestAppPrebuilt.apk"
+            value="/data/local/tmp/authfs/input.apk" />
+        <option name="push-file" key="CtsApkVerityTestAppPrebuilt.apk.fsv_sig"
+            value="/data/local/tmp/authfs/input.apk.fsv_sig" />
+    </target_preparer>
+
+    <target_preparer class="com.android.tradefed.targetprep.RunCommandTargetPreparer">
+        <option name="throw-if-cmd-fail" value="true" />
+        <!-- Now that the files are pushed to the device, enable fs-verity for the targeting file.
+             It works because the signature is trusted on all CTS compatible devices. -->
+        <option name="run-command" value="cd /data/local/tmp/authfs; ../fsverity enable input.apk --signature=input.apk.fsv_sig" />
     </target_preparer>
 
     <test class="com.android.compatibility.common.tradefed.testtype.JarHostTest" >